Skip to content

Commit 475be54

Browse files
committed
fix(list): do not use undefined variable before its initialization
Fixes #206
1 parent 874449d commit 475be54

File tree

1 file changed

+5
-4
lines changed

1 file changed

+5
-4
lines changed

dired-list.el

Lines changed: 5 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -336,10 +336,11 @@ and files matching `grep-find-ignored-files' are ignored.
336336
337337
If called with raw prefix argument \\[universal-argument], no
338338
files will be ignored."
339-
(interactive (let ((base-cmd (concat "find . "
340-
(if current-prefix-arg "" (dired-list--get-ignored-stuff dir))
341-
" -ls &")))
342-
(list (read-directory-name "Directory: " nil nil t)
339+
(interactive (let* ((dir (read-directory-name "Directory: " nil nil t))
340+
(base-cmd (concat "find . "
341+
(if current-prefix-arg "" (dired-list--get-ignored-stuff dir))
342+
" -ls &")))
343+
(list dir
343344
(read-from-minibuffer
344345
"Find command: "
345346
(cons base-cmd (string-match-p "-ls &" base-cmd))))))

0 commit comments

Comments
 (0)