Skip to content

Commit ea008cb

Browse files
lukasniestrojgeorgringer
authored andcommitted
[BUGFIX] display marker by geocodeUrl
Wait for the promise to resolve, otherwise the fallback location in kopenhagen is displayed as marker
1 parent 1070cc5 commit ea008cb

File tree

1 file changed

+2
-2
lines changed

1 file changed

+2
-2
lines changed

Resources/Public/JavaScript/esm/leaflet-backend.js

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -87,14 +87,14 @@ class LeafletBackendModule {
8787
document.body.appendChild(locationMapDiv);
8888
}
8989

90-
createMap() {
90+
async createMap() {
9191
if (
9292
(!this.latitude ||
9393
!this.longitude ||
9494
(this.latitude == 0 && this.longitude == 0)) &&
9595
this.geoCodeUrl != null
9696
) {
97-
this.geocode();
97+
await this.geocode();
9898
}
9999

100100
// The ultimate fallback: if one of the coordinates is empty, fallback to Kopenhagen.

0 commit comments

Comments
 (0)