mirror of https://github.com/M66B/FairEmail.git
Reset operation states on boot
This commit is contained in:
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…
Reference in New Issue