-
-
Notifications
You must be signed in to change notification settings - Fork 2.7k
refactor(outbox): enforce always one outbox folder per account and remove outboxFolderId from preferences #9852
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
refactor(outbox): enforce always one outbox folder per account and remove outboxFolderId from preferences #9852
Conversation
legacy/storage/src/main/java/com/fsck/k9/storage/migrations/MigrationTo75.kt
Show resolved
Hide resolved
legacy/storage/src/main/java/com/fsck/k9/storage/migrations/MigrationTo76.kt
Show resolved
Hide resolved
|
I might squash some commits, the ones with message starting with "use OutboxFolderManager...", to keep it easier to revert in case of need. |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Thank you for digging into this.
I just some little comments.
core/android/account/src/main/kotlin/net/thunderbird/core/android/account/LegacyAccountDto.kt
Outdated
Show resolved
Hide resolved
core/common/src/commonMain/kotlin/net/thunderbird/core/common/cache/TimeLimitedCache.kt
Show resolved
Hide resolved
...der/api/src/commonMain/kotlin/net/thunderbird/feature/mail/folder/api/OutboxFolderManager.kt
Outdated
Show resolved
Hide resolved
legacy/storage/src/main/java/com/fsck/k9/storage/migrations/MigrationTo76.kt
Outdated
Show resolved
Hide resolved
legacy/storage/src/main/java/com/fsck/k9/storage/migrations/MigrationTo76.kt
Outdated
Show resolved
Hide resolved
legacy/storage/src/main/java/com/fsck/k9/storage/migrations/MigrationTo76.kt
Outdated
Show resolved
Hide resolved
legacy/storage/src/main/java/com/fsck/k9/storage/migrations/MigrationTo75.kt
Outdated
Show resolved
Hide resolved
…nd create it if needed
…n DefaultDisplayFolderRepository
…n DefaultMessageCountsProvider
…n SpecialLocalFoldersCreator; migrate createSpecialLocalFolders to suspend function
…n FolderRepository
…n DefaultFolderProvider
…n MessageViewFragment
…n SendFailedNotificationController
…n MessagingController
…n SyncNotificationController
…Creator in favour of OutboxFolderManager
…n FolderInfoHolder
…n MessageListFragment
…n DisplayAddressHelper
…egacyAccountDto.outboxFolderId
…ting outbox folder
3e5a23b to
0b3ec8e
Compare
wmontwe
left a comment
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
LGTM
…x-state-entry-not-found-enforce-outbox refactor(outbox): enforce always one outbox folder per account and remove outboxFolderId from preferences
Fixes #8049.
This PR is meant to fix the issue where the Outbox gets removed from the database and inbox gets selected as also an outbox, causing the "IllegalStateException: No outbox_state entry for message with id " notification.
This solution focus on:
outboxFolderIdreference from the preference store;outboxFolderIdfrom theLegacyAccountandLegacyAccountDto.