File tree Expand file tree Collapse file tree 1 file changed +6
-1
lines changed
BlueMapCommon/webapp/src/js Expand file tree Collapse file tree 1 file changed +6
-1
lines changed Original file line number Diff line number Diff line change @@ -598,7 +598,12 @@ export class BlueMapApp {
598598 return ;
599599 }
600600
601- this . mapViewer . clearTileCache ( this . loadUserSetting ( "tileCacheHash" , this . mapViewer . tileCacheHash ) ) ;
601+ // Only reuse the user's tile cash hash if the current browser navigation event is not a reload.
602+ // If it's a reload, we assume the user is troubleshooting and actually wants to refresh the map.
603+ const [ entry ] = performance . getEntriesByType ( "navigation" ) ;
604+ if ( entry . type != "reload" ) {
605+ this . mapViewer . clearTileCache ( this . loadUserSetting ( "tileCacheHash" , this . mapViewer . tileCacheHash ) ) ;
606+ }
602607
603608 this . mapViewer . superSampling = this . loadUserSetting ( "superSampling" , this . mapViewer . data . superSampling ) ;
604609 this . mapViewer . data . loadedHiresViewDistance = this . loadUserSetting ( "hiresViewDistance" , this . mapViewer . data . loadedHiresViewDistance ) ;
You can’t perform that action at this time.
0 commit comments