Skip to content

Commit

Permalink
Merge pull request #1092 from octavm/patch-1
Browse files Browse the repository at this point in the history
Prevent token repeating in url
  • Loading branch information
jgravois authored Apr 24, 2018
2 parents d455bbd + 72b2760 commit ac117f1
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) {
if (this.options.token && config.urlTemplate.indexOf('token=') === -1) {
config.urlTemplate += ('?token=' + this.options.token);
}

Expand Down

0 comments on commit ac117f1

Please sign in to comment.