From 5f2cfc9f73e756fb337df70909fcd3d0bce56911 Mon Sep 17 00:00:00 2001 From: Jonas Bernoulli Date: Wed, 29 Nov 2023 18:14:39 +0100 Subject: [PATCH] transient--make-predicate-map: Only return if there is a parent Only prepare to return to the parent transient if there actually is a parent. The only negative effect of failing to do this was that the suffix was colored wrong, since `transient--do-return' falls back to behave like `transient--do-exit'. --- lisp/transient.el | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/lisp/transient.el b/lisp/transient.el index 99a98310..d1dd44d3 100644 --- a/lisp/transient.el +++ b/lisp/transient.el @@ -1810,7 +1810,7 @@ of the corresponding object." (defun transient--make-predicate-map () (let* ((default (transient--resolve-pre-command (oref transient--prefix transient-suffix))) - (return (eq default t)) + (return (and transient-current-prefix (eq default t))) (map (make-sparse-keymap))) (set-keymap-parent map transient-predicate-map) (when (or (and (slot-boundp transient--prefix 'transient-switch-frame)