branch: externals/devdocs
commit e9386e0f395d3b046261e9f1fdcfe68ddf674efb
Author: Augusto Stoffel <[email protected]>
Commit: Augusto Stoffel <[email protected]>
devdocs--read-entry: Issue user error on null input
See discussion in #25.
---
devdocs.el | 3 ++-
1 file changed, 2 insertions(+), 1 deletion(-)
diff --git a/devdocs.el b/devdocs.el
index d21424bae3..e6c75dc2ce 100644
--- a/devdocs.el
+++ b/devdocs.el
@@ -562,7 +562,8 @@ INITIAL-INPUT is passed to `completing-read'"
(cand (completing-read prompt coll nil t initial-input
'devdocs-history
(thing-at-point 'symbol))))
- (devdocs--get-data (car (member cand cands)))))
+ (devdocs--get-data (or (car (member cand cands))
+ (user-error "Not an entry!")))))
;;;###autoload
(defun devdocs-lookup (&optional ask-docs initial-input)