fix(mailbox): auto-refresh the INBOX in the background like every other folder#13205
Closed
ktogias wants to merge 1 commit into
Closed
fix(mailbox): auto-refresh the INBOX in the background like every other folder#13205ktogias wants to merge 1 commit into
ktogias wants to merge 1 commit into
Conversation
…er folder loadMailbox() runs on a 60s interval to keep the currently open folder up to date in the background. It explicitly skipped the INBOX (in addition to unified mailboxes), so unlike every other folder, the INBOX only ever synced once, when the view was first mounted, and never again for as long as it stayed open. New mail's unread count updates via other means, but the open message list itself never picked up new messages without a manual page reload. Checked git blame: this goes back to the feature's original introduction in 2020 with no documented reason for excluding the INBOX specifically, and no other mechanism in the codebase covers refreshing it instead. Kept the isUnified skip -- a unified mailbox combines multiple real mailboxes and doesn't map to the single-folder sync this method calls. Signed-off-by: Konstantinos Togias <info@ktogias.gr>
|
Thanks for opening your first pull request in this repository! ✌️ |
ChristophWurst
requested changes
Jul 3, 2026
ChristophWurst
left a comment
Member
There was a problem hiding this comment.
Thanks for the patch
This appears to be an agentic contribution. As per CONTRIBUTING.md you have to disclose that and make it transparent.
- PR template ignored by agent
- Commit trailer missing
This feature also already exists. You can find it here:
Lines 65 to 84 in b54bd0e
Author
|
You're right, and I'm sorry. I missed the guideline about the disclosure. Closing this -- you're right that App.vue's sync()/syncInboxes() already |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Summary
loadMailbox()runs on a 60s interval (setInterval(this.loadMailbox, 60000)inmounted()) to keep the currently open folder up to date in the background. It explicitly returned early for the INBOX (in addition to unified mailboxes):So unlike every other folder, the INBOX only ever synced once, when the view was first mounted, and never again for as long as it stayed open. In practice: a new message's unread-count badge updates (via a separate, lighter-weight path), but the open INBOX message list itself never picks it up without a manual full page reload.
I checked
git blame/history on this line — it goes back to the feature's original introduction in 2020 (9ed84f8ac) with no explanation in the commit message for excluding the INBOX specifically, and I couldn't find any other mechanism in the codebase (searched for othersetIntervalusage and any INBOX-specific refresh path) that covers refreshing it instead. If there's a reason I'm missing for the original exclusion, happy to adjust.Fix
Drops the INBOX-specific half of the condition. Kept the
isUnifiedskip as-is — a unified mailbox combines multiple real mailboxes and doesn't map to the single-foldersync()call this method makes.Test plan
npx eslint src/components/Mailbox.vue— clean, no errors or warnings.Mailbox.vueto extend; verified manually against a real instance with a large, occasionally slow-to-sync IMAP account — INBOX now picks up new mail within the 60s interval without a manual reload, matching every other folder's existing behavior.