]> git.notmuchmail.org Git - notmuch/commitdiff
emacs: notmuch-mua-add-more-hidden-headers: use local binding
authorJonas Bernoulli <jonas@bernoul.li>
Sun, 10 Jan 2021 18:47:19 +0000 (19:47 +0100)
committerDavid Bremner <david@tethera.net>
Fri, 15 Jan 2021 11:29:09 +0000 (07:29 -0400)
emacs/notmuch-mua.el

index 08c73c1637abf4bdb88101165a5f09c9723c770b..bbf059a22cb5487f669497631363a7c924b1d3d8 100644 (file)
@@ -217,11 +217,10 @@ Typically this is added to `notmuch-mua-send-hook'."
 (defun notmuch-mua-reply-crypto (parts)
   "Add mml sign-encrypt flag if any part of original message is encrypted."
   (cl-loop for part in parts
-          if (notmuch-match-content-type (plist-get part :content-type)
-                                         "multipart/encrypted")
+          for type = (plist-get part :content-type)
+          if (notmuch-match-content-type type "multipart/encrypted")
           do (mml-secure-message-sign-encrypt)
-          else if (notmuch-match-content-type (plist-get part :content-type)
-                                              "multipart/*")
+          else if (notmuch-match-content-type type "multipart/*")
           do (notmuch-mua-reply-crypto (plist-get part :content))))
 
 ;; There is a bug in Emacs' message.el that results in a newline