deltachat-core-rust
deltachat-core-rust copied to clipboard
feat: Sync chats deletion across devices
feat: Sync chats deletion across devices
Motivation: Now broadcast lists creation is synced across devices. Groups creation, in some means, too -- on a group promotion by a first message. So, to make this looking more feature-complete, sync chats deletion too.
An approach is to replay a user action on synchronised devices because the chat deletion is a complex procedure affecting several tables, self-chat, emitting the corresponding event etc.
Also this commit makes all deletions to happen in a transaction, to be on a safe side.
general comment: please describe a description for your PRs, summarizing the motivation/reason and the approach/solution.
general comment: please describe a description for your PRs, summarizing the motivation/reason and the approach/solution.
Added a commit message. Yes, i hurried to share this work. Actually it should be a draft w/o good commit messages
I have mixed feelings about chat deletion, users might expect it to delete all imap emails / messages from that chat too.
I wouldn't sync chat deletion before we sync message deletion.
I have mixed feelings about chat deletion, users might expect it to delete all imap emails / messages from that chat too.
I wouldn't sync chat deletion before we sync message deletion.
But these are independent things actually, one doesn't make another worse.
For deletion current plan is not to release it into 1.42 series and stabilize everything else first. Deletion is destructive and therefore dangerous, let's test how well pinning/renaming works first on a large scale.
There may be a problem with synchronising chats deletion -- if another device has DeleteServerAfter set, messages wouldn't be deleted from the server as a user might think. But this is the problem also with the current chat deletion functionality probably -- chat messages remain on the server.