Allow multiple primary accounts

This commit is contained in:
M66B
2018-12-27 17:01:07 +00:00
parent 3304732e9e
commit 38d4c4ae88
3 changed files with 20 additions and 8 deletions

View File

@@ -70,8 +70,8 @@ public interface DaoIdentity {
@Query("UPDATE identity SET error = :error WHERE id = :id")
int setIdentityError(long id, String error);
@Query("UPDATE identity SET `primary` = 0")
void resetPrimary();
@Query("UPDATE identity SET `primary` = 0 WHERE account = :account")
void resetPrimary(long account);
@Query("UPDATE identity SET tbd = 1 WHERE id = :id")
int setIdentityTbd(long id);