From 6ae0aa6a504c6023dfe234b507c95f146d668436 Mon Sep 17 00:00:00 2001 From: Fran Litterio Date: Sun, 27 Dec 2015 08:56:45 +0100 Subject: [PATCH] Run erc-kill-channel-hook always on exit * lisp/erc/erc.el (erc-kill-buffer-function): Run erc-kill-channel-hook when erc-kill-queries-on-quit is set (bug#21187). --- lisp/erc/erc.el | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/lisp/erc/erc.el b/lisp/erc/erc.el index a66338dff02..70e37348b6a 100644 --- a/lisp/erc/erc.el +++ b/lisp/erc/erc.el @@ -6702,7 +6702,7 @@ or `erc-kill-buffer-hook' if any other buffer." (cond ((eq (erc-server-buffer) (current-buffer)) (run-hooks 'erc-kill-server-hook)) - ((erc-channel-p (erc-default-target)) + ((erc-channel-p (or (erc-default-target) (buffer-name))) (run-hooks 'erc-kill-channel-hook)) (t (run-hooks 'erc-kill-buffer-hook))))) -- 2.39.5