1
0
mirror of https://github.com/Jermolene/TiddlyWiki5 synced 2024-06-22 05:13:15 +00:00

Fix bug when fitting to non-extistent bounds

This commit is contained in:
Jeremy Ruston 2023-09-09 15:40:55 +01:00
parent 65ac272832
commit fbcea2e26f

View File

@ -242,7 +242,11 @@ GeomapWidget.prototype.refreshMap = function() {
bounds = featureBounds;
}
});
this.map.fitBounds(bounds);
if(bounds) {
this.map.fitBounds(bounds);
} else {
this.map.fitWorld();
}
break;
default:
this.map.fitWorld();