branch: externals/consult-denote
commit b9aabc2218ae59ce94bbed447b6b861c16a1a120
Author: Protesilaos Stavrou <i...@protesilaos.com>
Commit: Protesilaos Stavrou <i...@protesilaos.com>

    Do not evaluate the 'denote-directory' twice in the file prompt
---
 consult-denote.el | 2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)

diff --git a/consult-denote.el b/consult-denote.el
index 3a38958d67..20df5db3ff 100644
--- a/consult-denote.el
+++ b/consult-denote.el
@@ -126,8 +126,8 @@ Return the absolute path to the matching file."
                           (denote-directory-files
                            (or denote-file-prompt-use-files-matching-regexp 
files-matching-regexp)
                            :omit-current nil nil has-identifier)))
-         (prompt (format "%s in %s: " (or prompt-text "Select FILE") 
(denote-directory)))
          (default-directory (denote-directory)) ; needed for the preview
+         (prompt (format "%s in %s: " (or prompt-text "Select FILE") 
default-directory))
          (input (consult--read
                  (denote--completion-table 'file relative-files)
                  :state (consult--file-preview)

Reply via email to