aboutsummaryrefslogtreecommitdiffhomepage
path: root/emacs
diff options
context:
space:
mode:
authorGravatar Tomi Ollila <tomi.ollila@iki.fi>2014-01-27 22:32:12 +0200
committerGravatar David Bremner <david@tethera.net>2014-01-30 12:21:25 -0400
commit9ac863c549e8022dc06d73e07d79a74ec7f0569f (patch)
treedce8383b91254c364644f9c4c9713dc4d00be704 /emacs
parent3e1d7f6476f94d9912e395872317606fb702f210 (diff)
emacs: ad-activate 'mm-shr after ad-disable-advice 'mm-shr
Imitated from "Enabling advice" in Emacs lisp manual... ad-disable-advice by itself only changes the enable flag for a piece of advice. To make the change take effect in the advised definition, the advice needs to be activated again.
Diffstat (limited to 'emacs')
-rw-r--r--emacs/notmuch-lib.el3
1 files changed, 2 insertions, 1 deletions
diff --git a/emacs/notmuch-lib.el b/emacs/notmuch-lib.el
index e6e9f97a..fa35fa9f 100644
--- a/emacs/notmuch-lib.el
+++ b/emacs/notmuch-lib.el
@@ -531,7 +531,8 @@ the given type."
(if (>= emacs-major-version 24)
(defadvice mm-shr (before load-gnus-arts activate)
(require 'gnus-art nil t)
- (ad-disable-advice 'mm-shr 'before 'load-gnus-arts)))
+ (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)
"Use the mm-decode/mm-view functions to display a part in the