Load error tile svg only if showLimitErrors is true

This commit is contained in:
rubenmoya 2017-11-15 16:24:13 +01:00
parent b597fba4ae
commit 23d2d2a60e

View File

@ -142,7 +142,9 @@ var CartoDatasource = require('./datasource');
this._shader = shader; this._shader = shader;
this._Map = this._shader.getDefault().getStyle({}, { zoom: 0 }); this._Map = this._shader.getDefault().getStyle({}, { zoom: 0 });
var img_names = this._shader.getImageURLs(); var img_names = this._shader.getImageURLs();
img_names.push(ERROR_IMG_URL); if (this.layer.showLimitErrors) {
img_names.push(ERROR_IMG_URL);
}
this._preloadIcons(img_names); this._preloadIcons(img_names);
}, },