mirror of
https://github.com/koala73/worldmonitor.git
synced 2026-04-25 17:14:57 +02:00
fix(country-intel): silently dismiss when geocode cannot identify a country (#1383)
Instead of showing an error dialog with "Could not identify a country at this location", simply close the panel and unpause the map. Clicking on ocean or unidentified areas no longer surfaces a useless error.
This commit is contained in:
@@ -134,12 +134,8 @@ export class CountryIntelManager implements AppModule {
|
||||
const geo = await reverseGeocode(lat, lon);
|
||||
if (token !== this.briefRequestToken) return;
|
||||
if (!geo) {
|
||||
if (this.ctx.countryBriefPage.showGeoError) {
|
||||
this.ctx.countryBriefPage.showGeoError(() => this.openCountryBrief(lat, lon));
|
||||
} else {
|
||||
this.ctx.countryBriefPage.hide();
|
||||
this.ctx.map?.setRenderPaused(false);
|
||||
}
|
||||
this.ctx.countryBriefPage.hide();
|
||||
this.ctx.map?.setRenderPaused(false);
|
||||
return;
|
||||
}
|
||||
|
||||
|
||||
Reference in New Issue
Block a user