X-Git-Url: https://git.notmuchmail.org/git?p=notmuch;a=blobdiff_plain;f=emacs%2Fnotmuch-lib.el;h=1e166c6afce53a501689c616f6478d7d3d496412;hp=19269e3c469b9adbf01776617d66bdf4974b1b86;hb=ce44657c9e4919b1e4bbbbbe37dbd72257d40736;hpb=f92342cb76fa3e1fa2f1c2e727f8ddf1a5c21b7d diff --git a/emacs/notmuch-lib.el b/emacs/notmuch-lib.el index 19269e3c..1e166c6a 100644 --- a/emacs/notmuch-lib.el +++ b/emacs/notmuch-lib.el @@ -539,9 +539,10 @@ the given type." (apply 'call-process (append (list notmuch-command nil (list t nil) nil) args)) (buffer-string)))))) -(defun notmuch-get-bodypart-content (msg part nth process-crypto) +(defun notmuch-get-bodypart-content (msg part process-crypto) (or (plist-get part :content) - (notmuch-get-bodypart-internal (notmuch-id-to-query (plist-get msg :id)) nth process-crypto))) + (notmuch-get-bodypart-internal (notmuch-id-to-query (plist-get msg :id)) + (plist-get part :id) process-crypto))) ;; Workaround: The call to `mm-display-part' below triggers a bug in ;; Emacs 24 if it attempts to use the shr renderer to display an HTML @@ -557,7 +558,7 @@ the given type." (ad-disable-advice 'mm-shr 'before 'load-gnus-arts) (ad-activate 'mm-shr))) -(defun notmuch-mm-display-part-inline (msg part nth content-type process-crypto) +(defun notmuch-mm-display-part-inline (msg part content-type process-crypto) "Use the mm-decode/mm-view functions to display a part in the current buffer, if possible." (let ((display-buffer (current-buffer))) @@ -573,7 +574,7 @@ current buffer, if possible." ;; test whether we are able to inline it (which includes both ;; capability and suitability tests). (when (mm-inlined-p handle) - (insert (notmuch-get-bodypart-content msg part nth process-crypto)) + (insert (notmuch-get-bodypart-content msg part process-crypto)) (when (mm-inlinable-p handle) (set-buffer display-buffer) (mm-display-part handle)