From 5b3989f3e17e20c6ee148077dd6fb3ed53ff9efc Mon Sep 17 00:00:00 2001 From: Max Nickel Date: Thu, 24 Oct 2019 18:33:38 -0400 Subject: [PATCH] fix removal of unread hook when filtering messages --- modules/email/notmuch/autoload.el | 4 ++-- modules/email/notmuch/config.el | 2 +- 2 files changed, 3 insertions(+), 3 deletions(-) diff --git a/modules/email/notmuch/autoload.el b/modules/email/notmuch/autoload.el index 6c273e526..12203587f 100644 --- a/modules/email/notmuch/autoload.el +++ b/modules/email/notmuch/autoload.el @@ -119,7 +119,7 @@ (notmuch-show-refresh-view t)) ;;;###autoload -(defun +notmuch-expand-only-unread-h () +(defun +notmuch-show-expand-only-unread-h () (interactive) (let ((unread nil) (open (notmuch-show-get-message-ids-for-open-messages))) @@ -127,7 +127,7 @@ (when (member "unread" (notmuch-show-get-tags)) (setq unread t)))) (when unread - (let ((notmuch-show-hook (remove '+notmuch/expand-only-unread-hook notmuch-show-hook))) + (let ((notmuch-show-hook (remove '+notmuch-show-expand-only-unread-h notmuch-show-hook))) (notmuch-show-filter-thread "tag:unread"))))) ;; diff --git a/modules/email/notmuch/config.el b/modules/email/notmuch/config.el index 6f200dbd3..75b660351 100644 --- a/modules/email/notmuch/config.el +++ b/modules/email/notmuch/config.el @@ -46,7 +46,7 @@ ;; (setq-hook! 'notmuch-show-mode-hook line-spacing 0) ;; only unfold unread messages in thread by default - (add-hook 'notmuch-show-hook '+notmuch-expand-only-unread-h) + (add-hook 'notmuch-show-hook '+notmuch-show-expand-only-unread-h) (add-hook 'doom-real-buffer-functions #'notmuch-interesting-buffer)