From 93a853a9e21738a3f3ce0ef1785e5c878090a605 Mon Sep 17 00:00:00 2001 From: Silvio Date: Wed, 29 Jul 2015 18:38:17 -0300 Subject: Strict mode --- gmap_arcgis.js | 11 +++++++---- 1 file changed, 7 insertions(+), 4 deletions(-) diff --git a/gmap_arcgis.js b/gmap_arcgis.js index 34e8f12..2057506 100644 --- a/gmap_arcgis.js +++ b/gmap_arcgis.js @@ -2,6 +2,8 @@ * Gmap ArcGIS wrapper. */ function gmapArcgis(config) { + 'use strict'; + /** * Extend Google Maps API. * See https://code.google.com/p/google-maps-extensions/source/browse/google.maps.Polygon.getBounds.js @@ -97,7 +99,8 @@ function gmapArcgis(config) { } //if (jQuery.browser.msie === false || jQuery.browser.msie === undefined) { - message = this.config.overlayMessage; + var css; + var message = this.config.overlayMessage; if (this.config.overlayCss != undefined) { css = this.config.overlayCss; @@ -475,7 +478,7 @@ function gmapArcgis(config) { var mark; // Hide/show each marker - for (i=0; i < markers.length; i++) { + for (var i=0; i < markers.length; i++) { // Determine where exactly our marker is if (markers[i].marker != undefined) { mark = markers[i].marker; @@ -750,10 +753,10 @@ function gmapArcgis(config) { cleanOverlays: function() { var overlays = [ 'layers', 'markers' ]; - for (i in overlays) { + for (var i in overlays) { var overlay = this.config[overlays[i]]; - for (element in overlay) { + for (var element in overlay) { if (overlay[element].infowindow != undefined) { delete this.config[overlays[i]][element].infowindow; } -- cgit v1.2.3