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:
Elie Habib
2026-03-10 17:04:16 +04:00
committed by GitHub
parent b01aedea7b
commit 1453a23a79

View File

@@ -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;
}