fix: ignore null-island location

Closes #149
This commit is contained in:
Jovan Krunić
2021-10-27 13:44:07 +02:00
parent e29a68bb03
commit d3188f5090
6 changed files with 86 additions and 26 deletions

View File

@@ -448,12 +448,15 @@ export class MapPageComponent {
* Show a single place
*/
async showItemModal(item: SCPlace) {
const placeWithoutGeo = {...item, geo: undefined};
const placeWithNullLocation = {
...item,
geo: {point: {coordinates: [0, 0]}},
};
this.modal = await this.modalController.create({
component: MapSingleModalComponent,
swipeToClose: true,
componentProps: {
item: placeWithoutGeo,
item: placeWithNullLocation,
dismissAction: () => {
this.modal.dismiss();
},