Phase-3 review (MEDIUM/data-loss). AccountDao.upsert(:30) is @Insert(onConflict=REPLACE); account_settings+signatures have ON DELETE CASCADE FKs to accounts.id. SQLite INSERT-OR-REPLACE on PK conflict = delete-then-insert, firing the cascade. So upsert of an EXISTING account id (re-adding an Outlook account — deterministic id outlook:$email; addOutlookAccount→insertAtEnd→upsert) cascade-deletes the account's settings + signatures permanently (ensureDefaults recreates settings but signatures are gone). No dup-account guard → reachable. Fix:@Update for edits + non-destructive insert (ABORT/IGNORE) for new accounts, or split create-vs-update so an existing row is never REPLACE-deleted (mirror the IGNORE already used in messages insertNew). Test.
Phase-3 review (MEDIUM/data-loss). `AccountDao.upsert`(:30) is `@Insert(onConflict=REPLACE)`; `account_settings`+`signatures` have `ON DELETE CASCADE` FKs to `accounts.id`. SQLite INSERT-OR-REPLACE on PK conflict = delete-then-insert, firing the cascade. So upsert of an EXISTING account id (re-adding an Outlook account — deterministic id `outlook:$email`; `addOutlookAccount`→`insertAtEnd`→`upsert`) cascade-deletes the account's settings + **signatures permanently** (ensureDefaults recreates settings but signatures are gone). No dup-account guard → reachable. **Fix:** `@Update` for edits + non-destructive insert (ABORT/IGNORE) for new accounts, or split create-vs-update so an existing row is never REPLACE-deleted (mirror the `IGNORE` already used in messages `insertNew`). Test.
Blocking a user prevents them from interacting with repositories, such as opening or commenting on pull requests or issues. Learn more about blocking a user.
Phase-3 review (MEDIUM/data-loss).
AccountDao.upsert(:30) is@Insert(onConflict=REPLACE);account_settings+signatureshaveON DELETE CASCADEFKs toaccounts.id. SQLite INSERT-OR-REPLACE on PK conflict = delete-then-insert, firing the cascade. So upsert of an EXISTING account id (re-adding an Outlook account — deterministic idoutlook:$email;addOutlookAccount→insertAtEnd→upsert) cascade-deletes the account's settings + signatures permanently (ensureDefaults recreates settings but signatures are gone). No dup-account guard → reachable. Fix:@Updatefor edits + non-destructive insert (ABORT/IGNORE) for new accounts, or split create-vs-update so an existing row is never REPLACE-deleted (mirror theIGNOREalready used in messagesinsertNew). Test.