Update updated_at right away if offline
This commit is contained in:
@@ -50,6 +50,10 @@ class SyncManager {
|
|||||||
}
|
}
|
||||||
|
|
||||||
syncOffline(items, callback) {
|
syncOffline(items, callback) {
|
||||||
|
// Update all items updated_at to now
|
||||||
|
for(var item of items) {
|
||||||
|
item.updated_at = new Date();
|
||||||
|
}
|
||||||
this.writeItemsToLocalStorage(items, true, function(responseItems){
|
this.writeItemsToLocalStorage(items, true, function(responseItems){
|
||||||
// delete anything needing to be deleted
|
// delete anything needing to be deleted
|
||||||
for(var item of items) {
|
for(var item of items) {
|
||||||
|
|||||||
Reference in New Issue
Block a user