From a31aa3157425b79a1d4c905dfffdfb5ea966dd1e Mon Sep 17 00:00:00 2001 From: teranisi Date: Sat, 15 Apr 2000 05:38:53 +0000 Subject: [PATCH] (elmo-archive-list-folders): Use `file-name-directory' if base folder does not exist. --- elmo/elmo-archive.el | 7 +++++-- 1 file changed, 5 insertions(+), 2 deletions(-) diff --git a/elmo/elmo-archive.el b/elmo/elmo-archive.el index eedc4c1..e1944ee 100644 --- a/elmo/elmo-archive.el +++ b/elmo/elmo-archive.el @@ -423,6 +423,10 @@ TYPE specifies the archiver's symbol." '(lambda (x) (regexp-quote (cdr x))) elmo-archive-suffix-alist "\\|")))) + (if (string-match "\\(.*\\)/$" base-folder) ; ends with '/'. + (setq base-folder (elmo-match-string 1 base-folder)) + (unless (file-directory-p path) + (setq base-folder (file-name-directory base-folder)))) (delq nil (mapcar @@ -434,8 +438,7 @@ TYPE specifies the archiver's symbol." elmo-archive-suffix-alist)))) (format "$%s;%s%s" (elmo-concat-path base-folder (elmo-match-string 1 x)) - suffix prefix) - )) + suffix prefix))) flist))) (elmo-localdir-list-folders-subr folder hierarchy)))) -- 1.7.10.4