From 60e7b7873939470a4a20099e7e1cb99c4a7e52b7 Mon Sep 17 00:00:00 2001 From: Henrik Lissner Date: Fri, 15 Jun 2018 18:32:53 +0200 Subject: [PATCH] Minor refactor of doom/describe-active-minor-mode --- core/autoload/help.el | 10 ++++------ 1 file changed, 4 insertions(+), 6 deletions(-) diff --git a/core/autoload/help.el b/core/autoload/help.el index 72c57ea06..7417800be 100644 --- a/core/autoload/help.el +++ b/core/autoload/help.el @@ -176,13 +176,11 @@ current file is in, or d) the module associated with the current major mode (see "Get information on an active minor mode. Use `describe-minor-mode' for a selection of all minor-modes, active or not." (interactive - (list (completing-read "Minor mode: " - (doom-active-minor-modes)))) + (list (completing-read "Minor mode: " (doom-active-minor-modes)))) (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)))))) + (cond ((stringp mode) (intern mode)) + ((symbolp mode) mode) + ((error "Expected a symbol/string, got a %s" (type-of mode)))))) ;;;###autoload (defun doom/what-face (&optional pos)