branch: elpa/dslide
commit da4e8dd4121ae7b97ff8142bce1831e47d25f5cb
Author: Psionik K <[email protected]>
Commit: Psionik K <[email protected]>

    user error instead of silent failure
    
    Signed-off-by: Psionik K <[email protected]>
---
 org-tree-slide.el | 5 +++--
 1 file changed, 3 insertions(+), 2 deletions(-)

diff --git a/org-tree-slide.el b/org-tree-slide.el
index 275eddd896..7aec095cba 100644
--- a/org-tree-slide.el
+++ b/org-tree-slide.el
@@ -670,8 +670,9 @@ This is displayed by default if 
`org-tree-slide-modeline-display' is nil.")
 
 (defun org-tree-slide--abort ()
   "Abort."
-  (when (equal major-mode 'org-mode)
-    (org-tree-slide--stop)))
+  (unless (equal major-mode 'org-mode)
+    (user-error "Not an org mode buffer"))
+  (org-tree-slide--stop))
 
 (defun org-tree-slide--play ()
   "Start slide view with the first tree of the org mode buffer."

Reply via email to