]> git.notmuchmail.org Git - notmuch/blobdiff - emacs/notmuch-draft.el
Merge branch 'release'
[notmuch] / emacs / notmuch-draft.el
index b13eb51c267f46431c53265df499d4d5c9628dea..f928be876a906c013f9ec13d345e9d95211461ba 100644 (file)
@@ -89,9 +89,8 @@ like they are intended to be sent encrypted
   "<#\\(part encrypt\\|secure.*mode=.*encrypt>\\)"
   "Regular expression matching mml tags indicating encryption of part or message.")
 
-(defvar notmuch-draft-id nil
+(defvar-local notmuch-draft-id nil
   "Message-id of the most recent saved draft of this message.")
-(make-variable-buffer-local 'notmuch-draft-id)
 
 (defun notmuch-draft--mark-deleted ()
   "Tag the last saved draft deleted.
@@ -136,7 +135,7 @@ Used when a new version is saved, or the message is sent."
     (let (secure-tag)
       (save-restriction
        (message-narrow-to-headers)
-       (setq secure-tag (message-fetch-field "X-Notmuch-Emacs-Secure" 't))
+       (setq secure-tag (message-fetch-field "X-Notmuch-Emacs-Secure" t))
        (message-remove-header "X-Notmuch-Emacs-Secure"))
       (message-goto-body)
       (when secure-tag
@@ -146,7 +145,7 @@ Used when a new version is saved, or the message is sent."
   "Returns t if there is an mml secure tag."
   (save-excursion
     (message-goto-body)
-    (re-search-forward notmuch-draft-encryption-tag-regex nil 't)))
+    (re-search-forward notmuch-draft-encryption-tag-regex nil t)))
 
 (defun notmuch-draft--query-encryption ()
   "Checks if we should save a message that should be encrypted.
@@ -208,7 +207,7 @@ applied to newly inserted messages)."
      (notmuch-draft-quote-some-mml)
      (notmuch-maildir-setup-message-for-saving)
      (notmuch-maildir-notmuch-insert-current-buffer
-      notmuch-draft-folder 't notmuch-draft-tags))
+      notmuch-draft-folder t notmuch-draft-tags))
     ;; We are now back in the original compose buffer. Note the
     ;; function notmuch-call-notmuch-process (called by
     ;; notmuch-maildir-notmuch-insert-current-buffer) signals an error