diff options
| author | Pedro Ribeiro Mendes JĂșnior <pedrormjunior@gmail.com> | 2026-04-15 18:48:05 -0300 |
|---|---|---|
| committer | Jonas Bernoulli <jonas@bernoul.li> | 2026-04-16 00:33:43 +0200 |
| commit | f0ead86bb4992b4bb56c48ba26b8b349d269053d (patch) | |
| tree | 92b9266ea27a72f3e52b322512823e1f9e471479 | |
| parent | 4a1c6389e70b80152160e265738dd87e60fef496 (diff) | |
magit-read-module-path: Fix previous change
Only augment the predicate if there actually is one.
Fix problem introduced in d527f833.
| -rw-r--r-- | lisp/magit-git.el | 9 |
1 files changed, 5 insertions, 4 deletions
diff --git a/lisp/magit-git.el b/lisp/magit-git.el index 729371d..7a36c08 100644 --- a/lisp/magit-git.el +++ b/lisp/magit-git.el @@ -2994,10 +2994,11 @@ out. Only existing branches can be selected." ;; the value of `default-directory' in that buffer is the same as in ;; the buffer from which completion was invoked. (magit-completing-read prompt (magit-list-module-paths) - (let ((dir default-directory)) - (lambda (module) - (let ((default-directory dir)) - (funcall predicate module)))) + (and predicate + (let ((dir default-directory)) + (lambda (module) + (let ((default-directory dir)) + (funcall predicate module))))) t nil nil (magit-module-at-point predicate))) |
