1
0
Fork 0
mirror of https://git.sr.ht/~rjarry/aerc synced 2025-11-27 11:44:03 +01:00
aerc/lib
Simon Martin 7be878ac50 imap: consistently honour message ordering preferences during updates
As reported by bonswouar on IRC, the mail received hook is not invoked
when a new mail is received on an account that's not currently active,
only when that account is activated.

This is due to a bug in MessageStore.Update, that wrongly assumes that
messages in a directory are displayed in increasing UID order - this is
only the case when reverse-msglist-order (that defaults to false) is
true. So unless there's less than one page worth of messages in a
directory or reverse-msglist-order is true, MessageStore.Update will
think that new messages are outside of the current page, and not fetch
their headers (this is what might trigger the mail received hook).

This patch ensures that the order is properly taken into account, and
makes the mail received hook be invoked whether the account is active or
not.

Signed-off-by: Simon Martin <simon@nasilyan.com>
Acked-by: Robin Jarry <robin@jarry.cc>
2025-11-05 10:42:13 +01:00
..
auth lint: homogenize operations and minor fixes (gocritic) 2022-08-04 21:58:01 +02:00
autoconfig chore: switch to using stdlib helper functions 2025-08-04 12:47:05 +02:00
calendar calendar: make invitation matching case-insensitive 2024-02-11 21:24:18 +01:00
crypto config: allow specifying the temporary directory 2025-10-30 21:17:44 +01:00
format ui: properly trim spaces from addresses 2025-05-21 18:30:55 +02:00
hooks reload: fix crash when reloading via IPC 2025-09-23 14:02:37 +02:00
ipc treewide: fix English spelling 2025-01-21 13:39:01 +01:00
iterator treewide: replace interface{} with any 2025-04-07 10:51:05 +02:00
jwz lib: vendor-in the jwz library 2025-08-28 09:28:16 +02:00
log treewide: replace interface{} with any 2025-04-07 10:51:05 +02:00
marker chore: switch to using stdlib helper functions 2025-08-04 12:47:05 +02:00
notmuch codespell: fix lib/notmuch/directory.go: firs => first 2025-02-01 10:06:41 +01:00
pama chore: switch to using stdlib helper functions 2025-08-04 12:47:05 +02:00
parse treewide: replace interface{} with any 2025-04-07 10:51:05 +02:00
pinentry reload: fix crash when reloading via IPC 2025-09-23 14:02:37 +02:00
rfc822 rfc822: try harder to decode invalid address headers 2025-05-07 17:13:23 +02:00
send smtp: add option to request DSN for successful deliveries 2025-03-09 00:40:38 +01:00
sort treewide: replace uint32 uids with opaque strings 2024-08-28 12:06:01 +02:00
state reload: fix crash when reloading via IPC 2025-09-23 14:02:37 +02:00
templates ui: properly trim spaces from addresses 2025-05-21 18:30:55 +02:00
ui grid: fix crash upon mouse event on not yet drawn grid 2025-09-26 16:54:32 +02:00
watchers watchers: fix checking error on darwin 2025-03-30 21:33:20 +02:00
xdg history: read the history file from XDG_STATE_HOME 2024-10-24 22:13:51 +02:00
attachment.go attach: fix content-transfer-encoding for rfc822 attachments 2024-10-24 22:13:51 +02:00
dirstore.go dirstore: list the folders in arrival order 2023-05-28 18:21:26 +02:00
dirstore_test.go dirstore: list the folders in arrival order 2023-05-28 18:21:26 +02:00
emlview.go rfc822: parse multipart messages on a best efforts basis 2024-11-21 22:27:19 +01:00
history.go Add command history and cycling 2019-07-26 14:29:34 -04:00
keepalive_dummy.go format: reformat code with go 1.17 2021-12-11 23:24:08 +01:00
keepalive_linux.go format: reformat code with go 1.17 2021-12-11 23:24:08 +01:00
messageview.go chore: switch to using stdlib helper functions 2025-08-04 12:47:05 +02:00
msgstore.go imap: consistently honour message ordering preferences during updates 2025-11-05 10:42:13 +01:00
notmuch_version.go main: improve version string 2024-02-01 00:59:01 +01:00
notmuch_version_dummy.go main: improve version string 2024-02-01 00:59:01 +01:00
oauthbearer.go lint: work nicely with wrapped errors (errorlint) 2022-08-04 21:58:04 +02:00
open.go reload: fix crash when reloading via IPC 2025-09-23 14:02:37 +02:00
structure_helpers.go lib: introduce FindMIMEPart, adapt Find{Plain,Calendar}text 2023-12-30 15:42:09 +01:00
structure_helpers_test.go lint: apply new formatting rules 2022-08-01 10:44:52 +02:00
threadbuilder.go lib: vendor-in the jwz library 2025-08-28 09:28:16 +02:00
xoauth2.go xdg: get rid of deprecated dependencies 2023-08-27 18:44:12 +02:00