From 4da96b3b45b4e5a0e15b4485a73798a85265874f Mon Sep 17 00:00:00 2001 From: ztimson Date: Mon, 2 Sep 2019 20:59:23 -0400 Subject: [PATCH] Saving event only triggered for map, not location --- src/app/services/sync.service.ts | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/src/app/services/sync.service.ts b/src/app/services/sync.service.ts index c6d4ce5..0662deb 100644 --- a/src/app/services/sync.service.ts +++ b/src/app/services/sync.service.ts @@ -144,7 +144,6 @@ export class SyncService { } save(map=true, location=true) { - this.status.next('saving'); let promises = []; if(location && this.locationDoc && this.locationChanged) { @@ -152,6 +151,7 @@ export class SyncService { } if(map && this.mapDoc && this.mapChanged) { + this.status.next('saving'); let map = this.mapData.value; Object.values(map).filter(val => Array.isArray(val)).forEach(val => val.filter(s => s.new).forEach(s => delete s.new)); delete map.locations;