From b0eee1c694f12a08fa868f93587532c031a7b59b Mon Sep 17 00:00:00 2001 From: Silvio Date: Tue, 11 Aug 2015 15:42:42 -0300 Subject: Check if sliders is defined --- gmap_arcgis.js | 9 +++++++++ 1 file changed, 9 insertions(+) diff --git a/gmap_arcgis.js b/gmap_arcgis.js index e804707..4cd0fab 100644 --- a/gmap_arcgis.js +++ b/gmap_arcgis.js @@ -551,6 +551,15 @@ function gmapArcgis(config) { // jQuery slider wrapper slider: function(element, slider) { var self = this; + + if (self.config.sliders == undefined) { + self.config.sliders = {}; + } + + if (self.config.sliders[slider] == undefined) { + self.config.sliders[slider] = {}; + } + var type = (self.config.sliders[slider].type != undefined) ? self.config.sliders[slider].type : 'slider'; var value = (self.config.sliders[slider].value != undefined) ? self.config.sliders[slider].value : 1; var min = (self.config.sliders[slider].min != undefined) ? self.config.sliders[slider].min : 1; -- cgit v1.2.3