diff --git a/mapbox-gl-control.html b/mapbox-gl-control.html index 3337da8..cd73b11 100644 --- a/mapbox-gl-control.html +++ b/mapbox-gl-control.html @@ -193,7 +193,7 @@ } _createIControl(map, icontrol, icontrolOptions) { - if (!map || !icontrol || this.icontrol) return; + if (!map || !icontrol || !this.icontrol) return; // name of the control if (typeof icontrol === 'string') { this.icontrol = new mapboxgl[icontrol](icontrolOptions);