aboutsummaryrefslogtreecommitdiff
path: root/sx-question-mode.el
diff options
context:
space:
mode:
Diffstat (limited to 'sx-question-mode.el')
-rw-r--r--sx-question-mode.el2
1 files changed, 2 insertions, 0 deletions
diff --git a/sx-question-mode.el b/sx-question-mode.el
index 6583961..d1732fb 100644
--- a/sx-question-mode.el
+++ b/sx-question-mode.el
@@ -150,6 +150,8 @@ Optional argument _ is for `push-button'."
(let ((ov (or (sx-question-mode--section-overlays-at
(line-end-position))
(sx-question-mode--section-overlays-at (point)))))
+ (unless (overlayp ov)
+ (sx-user-error "Not inside a question or answer"))
(goto-char (overlay-start ov))
(forward-line 0)
(overlay-put