mirror of
https://github.com/Jermolene/TiddlyWiki5
synced 2025-01-15 11:45:40 +00:00
Fix geospatial plugin map state loading (#8511)
This commit is contained in:
parent
0aa9cf6669
commit
7bf2fee15e
@ -292,7 +292,7 @@ GeomapWidget.prototype.setMapView = function() {
|
||||
this.map.setMaxZoom($tw.utils.parseInt(this.getAttribute("maxZoom")));
|
||||
}
|
||||
// Set the view to the content of the state tiddler
|
||||
var stateTiddler = this.geomapStateTitle && this.wiki.getTiddler(this.geomapStateTitle);
|
||||
var stateTiddler = this.getAttribute("state") && this.wiki.getTiddler(this.getAttribute("state"));
|
||||
if(stateTiddler) {
|
||||
this.map.setView([$tw.utils.parseNumber(stateTiddler.fields.lat,0),$tw.utils.parseNumber(stateTiddler.fields.long,0)], $tw.utils.parseNumber(stateTiddler.fields.zoom,0));
|
||||
return true;
|
||||
|
Loading…
Reference in New Issue
Block a user