We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
1 parent 7dcc506 commit 0c99017Copy full SHA for 0c99017
src/plots/mapbox/layers.js
@@ -202,21 +202,16 @@ function convertOpts(opts) {
202
function convertSourceOpts(opts) {
203
var sourceType = opts.sourcetype;
204
var source = opts.source;
205
- var sourceOpts = {
206
- type: sourceType
207
- };
+ var sourceOpts = {type: sourceType};
208
var field;
+
209
if(sourceType === 'geojson') {
210
field = 'data';
211
} else if(sourceType === 'vector') {
212
field = typeof source === 'string' ? 'url' : 'tiles';
213
} else if(sourceType === 'raster') {
214
field = 'tiles';
215
sourceOpts.tileSize = 256;
216
- for(var index = 0; index < source.length; index++) {
217
- var url = source[index];
218
- source[index] = decodeURIComponent(url);
219
- }
220
}
221
222
sourceOpts[field] = source;
0 commit comments