From e75f6be6cc117b0a30158a47c3231035f8ccdc20 Mon Sep 17 00:00:00 2001 From: Leo Vivier Date: Fri, 15 May 2020 00:03:18 +0200 Subject: [PATCH] Fix dired default file operation (bug#41261) * lisp/dired-aux.el (dired-dwim-target-directories): Restore pre-emacs-27 behavior of 'dired-dwim-target'. --- lisp/dired-aux.el | 7 +++---- 1 file changed, 3 insertions(+), 4 deletions(-) diff --git a/lisp/dired-aux.el b/lisp/dired-aux.el index 0069c1744dc..7f988540c2c 100644 --- a/lisp/dired-aux.el +++ b/lisp/dired-aux.el @@ -2002,10 +2002,9 @@ Optional arg HOW-TO determines how to treat the target. (format prompt (dired-mark-prompt arg files)) dir default)) (defun dired-dwim-target-directories () - (cond ((functionp dired-dwim-target) - (funcall dired-dwim-target)) - (dired-dwim-target - (dired-dwim-target-next)))) + (if (functionp dired-dwim-target) + (funcall dired-dwim-target) + (dired-dwim-target-next))) (defun dired-dwim-target-next (&optional all-frames) ;; Return directories from all next windows with dired-mode buffers. -- 2.39.2