mirror of
https://github.com/mempool/mempool.git
synced 2025-01-19 05:34:03 +01:00
Handle city-states in geolocation component
This commit is contained in:
parent
8c2d0e1d6c
commit
555425d97e
@ -70,6 +70,12 @@ export class GeolocationComponent implements OnChanges {
|
|||||||
if (this.type === 'node') {
|
if (this.type === 'node') {
|
||||||
const city = this.data.city ? this.data.city : '';
|
const city = this.data.city ? this.data.city : '';
|
||||||
|
|
||||||
|
// Handle city-states like Singapore or Hong Kong
|
||||||
|
if (city && city === this.data?.country) {
|
||||||
|
this.formattedLocation = `${this.data.country} ${getFlagEmoji(this.data.iso)}`;
|
||||||
|
return;
|
||||||
|
}
|
||||||
|
|
||||||
// City
|
// City
|
||||||
this.formattedLocation = `${city}`;
|
this.formattedLocation = `${city}`;
|
||||||
|
|
||||||
|
Loading…
Reference in New Issue
Block a user