]> git.notmuchmail.org Git - notmuch/blobdiff - emacs/notmuch-show.el
emacs: Increase consistency of library headers
[notmuch] / emacs / notmuch-show.el
index f1cd92fe6e0b9a588f66fddd6d8a521607963677..b0f2d28bd6f02057f6e524d81fdcde5d6b46f864 100644 (file)
@@ -1,4 +1,4 @@
-;;; notmuch-show.el --- displaying notmuch forests.
+;;; notmuch-show.el --- displaying notmuch forests
 ;;
 ;; Copyright © Carl Worth
 ;; Copyright © David Edmondson
@@ -446,8 +446,8 @@ parsing fails."
     (error (cons address nil))))
 
 (defun notmuch-show-clean-address (address)
-  "Try to clean a single email ADDRESS for display.  Return
-unchanged ADDRESS if parsing fails."
+  "Try to clean a single email ADDRESS for display.
+Return unchanged ADDRESS if parsing fails."
   (let* ((clean-address (notmuch-clean-address address))
         (p-address (car clean-address))
         (p-name (cdr clean-address)))
@@ -505,21 +505,17 @@ message at DEPTH in the current thread."
 
 (defun notmuch-show-insert-part-header (nth content-type declared-type
                                            &optional name comment)
-  (let ((button)
-       (base-label (concat (and name (concat name ": "))
+  (let ((base-label (concat (and name (concat name ": "))
                            declared-type
                            (and (not (string-equal declared-type content-type))
                                 (concat " (as " content-type ")"))
                            comment)))
-    (setq button
-         (insert-button
-          (concat "[ " base-label " ]")
-          :base-label base-label
-          :type 'notmuch-show-part-button-type
-          :notmuch-part-hidden nil))
-    (insert "\n")
-    ;; return button
-    button))
+    (prog1 (insert-button
+           (concat "[ " base-label " ]")
+           :base-label base-label
+           :type 'notmuch-show-part-button-type
+           :notmuch-part-hidden nil)
+      (insert "\n"))))
 
 (defun notmuch-show-toggle-part-invisibility (&optional button)
   (interactive)