summaryrefslogtreecommitdiff
path: root/corfu.el
diff options
context:
space:
mode:
authorDaniel Mendler <mail@daniel-mendler.de>2025-05-11 21:04:00 +0200
committerDaniel Mendler <mail@daniel-mendler.de>2025-05-11 21:04:00 +0200
commit60baa17ee99e333c17e9963c8c18570094053819 (patch)
treee19b0332637fabe7cb8a1b9e7ff8818c95a53f71 /corfu.el
parent5aef01a35fa9485571eb7b28b2b77958a5e2fb1a (diff)
corfu--guard: Simplify
Diffstat (limited to 'corfu.el')
-rw-r--r--corfu.el8
1 files changed, 2 insertions, 6 deletions
diff --git a/corfu.el b/corfu.el
index 58a01e0..3b10675 100644
--- a/corfu.el
+++ b/corfu.el
@@ -872,14 +872,10 @@ and the stack trace is shown in the *Messages* buffer."
(condition-case nil
(progn ,@body nil)
((debug error) t)))))
- (cond
- (debug-on-error
- (let ((debugger #'corfu--debug))
- (funcall body)))
- ((funcall body)
+ (when (or debug-on-error (funcall body))
(let ((debug-on-error t)
(debugger #'corfu--debug))
- (funcall body))))))
+ (funcall body)))))
(defun corfu--post-command ()
"Refresh Corfu after last command."