Fix cache poisoning on initial tiles on view

This commit is contained in:
Michael Primm 2023-05-09 20:47:23 -05:00
parent 3f2d9dd5df
commit 7bcce9c7e0
1 changed files with 3 additions and 1 deletions

View File

@ -194,7 +194,9 @@ var DynmapTileLayer = L.TileLayer.extend({
if (!url) {
this._cachedTileUrls[tileName] = url = this.options.dynmap.getTileUrl(tileName);
}
if (typeof timestamp === 'undefined') {
timestamp = this.options.dynmap.inittime
}
if(typeof timestamp !== 'undefined') {
url += (url.indexOf('?') === -1 ? '?timestamp=' + timestamp : '&timestamp=' + timestamp);
}