summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
-rw-r--r--lisp/transient.el6
1 files changed, 4 insertions, 2 deletions
diff --git a/lisp/transient.el b/lisp/transient.el
index f4fd0a0..02b8479 100644
--- a/lisp/transient.el
+++ b/lisp/transient.el
@@ -3179,8 +3179,10 @@ The last value is \"don't use any of these switches\"."
"Elsewhere use the reader of the infix command COMMAND.
Use this if you want to share an infix's history with a regular
stand-alone command."
- (cl-letf (((symbol-function #'transient--show) #'ignore))
- (transient-infix-read (transient--suffix-prototype command))))
+ (if-let ((obj (transient--suffix-prototype command)))
+ (cl-letf (((symbol-function #'transient--show) #'ignore))
+ (transient-infix-read obj))
+ (error "Not a suffix command: `%s'" command)))
;;;; Readers