Reset operation states on boot

pull/174/head
M66B 6 years ago
parent a650fdc82b
commit e29ef76d59

@ -127,6 +127,9 @@ public interface DaoOperation {
@Query("UPDATE operation SET state = :state WHERE id = :id")
int setOperationState(long id, String state);
@Query("UPDATE operation SET state = NULL")
int resetOperationStates();
@Query("UPDATE operation SET error = :error WHERE id = :id")
int setOperationError(long id, String error);

@ -1678,6 +1678,9 @@ public class ServiceSynchronize extends ServiceBase implements SharedPreferences
db.folder().setFolderSyncState(folder.id, null);
}
// Reset operations
db.operation().resetOperationStates();
// Restore notifications
db.message().clearNotifyingMessages();

Loading…
Cancel
Save