mirror of https://github.com/M66B/FairEmail.git
Prevent operation invalidation
This commit is contained in:
parent
415469fb7e
commit
6299eaa317
|
@ -126,16 +126,16 @@ public interface DaoOperation {
|
|||
" AND name = :name")
|
||||
int getOperationCount(long folder, long message, String name);
|
||||
|
||||
@Query("UPDATE operation SET tries = :tries WHERE id = :id")
|
||||
@Query("UPDATE operation SET tries = :tries WHERE id = :id AND tries <> :tries")
|
||||
int setOperationTries(long id, int tries);
|
||||
|
||||
@Query("UPDATE operation SET state = :state WHERE id = :id")
|
||||
@Query("UPDATE operation SET state = :state WHERE id = :id AND state <> :state")
|
||||
int setOperationState(long id, String state);
|
||||
|
||||
@Query("UPDATE operation SET state = NULL")
|
||||
@Query("UPDATE operation SET state = NULL WHERE state IS NOT NULL")
|
||||
int resetOperationStates();
|
||||
|
||||
@Query("UPDATE operation SET error = :error WHERE id = :id")
|
||||
@Query("UPDATE operation SET error = :error WHERE id = :id AND error <> :error")
|
||||
int setOperationError(long id, String error);
|
||||
|
||||
@Insert
|
||||
|
|
Loading…
Reference in New Issue