Skip to content

Commit

Permalink
Prevent token repeating in url
Browse files Browse the repository at this point in the history
Fix for Esri#1090
  • Loading branch information
octavm authored Apr 24, 2018
1 parent 04b051b commit 722498c
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion src/Layers/BasemapLayer.js
Original file line number Diff line number Diff line change
Expand Up @@ -204,7 +204,7 @@ export var BasemapLayer = TileLayer.extend({

Util.setOptions(this, tileOptions);

if (this.options.token && !config.urlTemplate.includes('token=')) {
if (this.options.token && config.urlTemplate.indexOf('token=') === -1) {
config.urlTemplate += ('?token=' + this.options.token);
}

Expand Down

0 comments on commit 722498c

Please sign in to comment.