doom/what-minor-mode: accept symbols & handle errors
This commit is contained in:
parent
b4986e908a
commit
c60de062ce
1 changed files with 5 additions and 1 deletions
|
@ -32,7 +32,11 @@ selection of all minor-modes, active or not."
|
|||
(interactive
|
||||
(list (completing-read "Minor mode: "
|
||||
(doom-active-minor-modes))))
|
||||
(describe-minor-mode-from-symbol (intern mode)))
|
||||
(describe-minor-mode-from-symbol
|
||||
(cl-typecase mode
|
||||
(string (intern mode))
|
||||
(symbol mode)
|
||||
(t (error "Expected a symbol/string, got a %s" (type-of mode))))))
|
||||
|
||||
;;;###autoload
|
||||
(defun doom/am-i-secure ()
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue