diff options
author | Foo <rasmus@gmx.us> | 2016-02-08 13:28:37 +1100 |
---|---|---|
committer | Lars Ingebrigtsen <larsi@gnus.org> | 2016-02-08 13:28:37 +1100 |
commit | 357ae5dba5faac5ff48ebb971cb29500f87f02a6 (patch) | |
tree | 97fc02b211a7ac17899c28df8ef7a8e0f88e7f72 /lisp/gnus/gnus-notifications.el | |
parent | d0c29576099b02ba75c2458f4c3ac175d1ba9250 (diff) | |
download | emacs-357ae5dba5faac5ff48ebb971cb29500f87f02a6.tar.gz |
Allow various Gnus and Message address variables to be functions
* doc/misc/gnus.texi (To From Newsgroups):
gnus-ignored-from-addresses can be a function.
* doc/misc/message.texi (Wide Reply):
message-dont-reply-to-names can be a function.
* lisp/gnus/gnus-icalendar.el (gnus-icalendar-identities):
message-alternative-emails can be a function.
* lisp/gnus/gnus-notifications.el (gnus-notifications):
message-alternative-emails can be a function (bug#22315).
* lisp/gnus/gnus-sum.el
(gnus-summary-from-or-to-or-newsgroups):
gnus-ignored-from-addresses can be a function (bug#22315).
Diffstat (limited to 'lisp/gnus/gnus-notifications.el')
-rw-r--r-- | lisp/gnus/gnus-notifications.el | 6 |
1 files changed, 4 insertions, 2 deletions
diff --git a/lisp/gnus/gnus-notifications.el b/lisp/gnus/gnus-notifications.el index 54a75b69c85..5a116cc0f75 100644 --- a/lisp/gnus/gnus-notifications.el +++ b/lisp/gnus/gnus-notifications.el @@ -180,8 +180,10 @@ This is typically a function to add in ;; Ignore mails from ourselves (unless (and gnus-ignored-from-addresses address - (gnus-string-match-p gnus-ignored-from-addresses - address)) + (cond ((functionp gnus-ignored-from-addresses) + (funcall gnus-ignored-from-addresses address)) + (t (gnus-string-match-p (gnus-ignored-from-addresses) + address)))) (let* ((photo-file (gnus-notifications-get-photo-file address)) (notification-id (gnus-notifications-notify (or (car address-components) address) |