Closed raviSussol closed 6 months ago
If so I think that logic should be in function* syncAll({ ... }) If there's nothing to sync, you could skip the authenticate and other steps and just yield put(SyncAction.updateIsSyncing(false));`?
That wouldn't stop from making api call (other than authenticate) to the server if we just check syncQueueManager.length
in the syncAll
- have to individually check each type records (sensor, temperature-log & temperature-breach) to really make sure either of api call only be made if there is/are specific type of records in the syncLog
. So thought better to check in their main functions.
332c60f should resolve it.
Thanks for reviewing @jmbrunskill!
Fixes #294
Makes requests for sensor, temparature log & temperature breach if there is/are data in the syncLog to be pushed.