]> git.eshelyaron.com Git - emacs.git/commitdiff
repeat-mode: Don't echo unset keys in help message
authorVisuwesh <visuweshm@gmail.com>
Tue, 14 Jun 2022 17:29:47 +0000 (22:59 +0530)
committerJuri Linkov <juri@linkov.net>
Wed, 15 Jun 2022 07:24:33 +0000 (10:24 +0300)
* repeat.el (repeat-echo-message-string): Check if the key is set.
(bug#55977)

lisp/repeat.el

index ea4e3d0bd81d9496a7be65155ec550a3b2bd5450..94ea9f7ac1fe4bd5096788b84c84d156c0958506 100644 (file)
@@ -500,7 +500,7 @@ See `describe-repeat-maps' for a list of all repeatable commands."
 (defun repeat-echo-message-string (keymap)
   "Return a string with a list of repeating keys."
   (let (keys)
-    (map-keymap (lambda (key _) (push key keys)) keymap)
+    (map-keymap (lambda (key cmd) (and cmd (push key keys))) keymap)
     (format-message "Repeat with %s%s"
                     (mapconcat (lambda (key)
                                  (key-description (vector key)))