From 78db91bdd2b03f98f2aa3169319cdef0e2ba1abe Mon Sep 17 00:00:00 2001 From: Henrik Lissner Date: Sun, 24 Sep 2017 18:41:12 +0200 Subject: [PATCH] Check if buffer/window is live in doom-popup-p --- core/autoload/popups.el | 6 ++++-- 1 file changed, 4 insertions(+), 2 deletions(-) diff --git a/core/autoload/popups.el b/core/autoload/popups.el index dc1acfe8d..77a11cdbc 100644 --- a/core/autoload/popups.el +++ b/core/autoload/popups.el @@ -8,9 +8,11 @@ current window if omitted." (when-let (target (or target (selected-window))) (cond ((bufferp target) - (buffer-local-value 'doom-popup-mode target)) + (and (buffer-live-p target) + (buffer-local-value 'doom-popup-mode target))) ((windowp target) - (and (window-parameter target 'popup) + (and (window-live-p target) + (window-parameter target 'popup) target))))) ;;;###autoload