From db4436eaf97718a1d24117ee082361c0cb854b8b Mon Sep 17 00:00:00 2001 From: Amin Bandali Date: Fri, 17 Jan 2020 22:33:03 -0500 Subject: [PATCH] Fix the notification action for PRIVMSG in erc-notifications-notify * lisp/erc/erc-desktop-notifications.el (erc-notifications-notify): explicitly request the buffer for `nick', rather than relying on (current-buffer) returning it. That works fine for the very first PRIVMSG sent by `nick', but ERC seems to handle subsequent PRIVMSGs differently, where (current-buffer) would return the server buffer rather than the existing buffer for PRIVMSGs from `nick'. --- lisp/erc/erc-desktop-notifications.el | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/lisp/erc/erc-desktop-notifications.el b/lisp/erc/erc-desktop-notifications.el index d8b09324a65..61412e0918d 100644 --- a/lisp/erc/erc-desktop-notifications.el +++ b/lisp/erc/erc-desktop-notifications.el @@ -60,7 +60,7 @@ This will replace the last notification sent with this function." (dbus-ignore-errors (setq erc-notifications-last-notification - (let ((channel (current-buffer))) + (let ((channel (erc-get-buffer nick))) (notifications-notify :bus erc-notifications-bus :title (format "%s in %s" (xml-escape-string nick) -- 2.39.2