diff options
author | Thanos Apollo <[email protected]> | 2024-02-06 06:24:54 +0200 |
---|---|---|
committer | Thanos Apollo <[email protected]> | 2024-02-06 06:25:17 +0200 |
commit | eb6011d82e0f334f167f525f8759f2d50859c954 (patch) | |
tree | fcc0089935811ea6dac77469715a1a3a1105be38 /gnosis.el | |
parent | 47b8c3190bf40acc13226aab37d3121e7d932af4 (diff) |
gnosis-display-hint: adjust for when hint is nil
Diffstat (limited to 'gnosis.el')
-rw-r--r-- | gnosis.el | 9 |
1 files changed, 5 insertions, 4 deletions
@@ -266,10 +266,11 @@ SUCCESS is t when user-input is correct, else nil" (defun gnosis-display-hint (hint) "Display HINT." - (goto-char (point-max)) - (insert - (propertize "\n\n-----\n" 'face 'gnosis-face-seperator) - (propertize hint 'face 'gnosis-face-hint))) + (let ((hint (or hint ""))) + (goto-char (point-max)) + (insert + (propertize "\n\n-----\n" 'face 'gnosis-face-seperator) + (propertize hint 'face 'gnosis-face-hint)))) (cl-defun gnosis-display-cloze-reveal (&key (cloze-char gnosis-cloze-string) replace (success t) (face nil)) "Replace CLOZE-CHAR with REPLACE. |