branch: elpa/helm commit 44b8eb8a17d0e13d641b57e0e7d9853d2d9b097c Author: Thierry Volpiatto <thie...@posteo.net> Commit: Thierry Volpiatto <thie...@posteo.net>
Fix bug #2547 with completing-read default Clause handling conses should be treated before the one handling both symbol and string. --- helm-mode.el | 10 +++++----- 1 file changed, 5 insertions(+), 5 deletions(-) diff --git a/helm-mode.el b/helm-mode.el index 73d15247d0..d0af930bdc 100644 --- a/helm-mode.el +++ b/helm-mode.el @@ -533,11 +533,7 @@ If COLLECTION is an `obarray', a TEST should be needed. See `obarray'." (defun helm-cr-default (default cands) (delq nil - (cond ((and (not (equal default "")) - (string= helm-pattern "")) - (cons default (delete (helm-stringify default) - cands))) - ((and (consp default) (string= helm-pattern "")) + (cond ((and (consp default) (string= helm-pattern "")) (append (cl-loop for d in default ;; Don't convert ;; nil to "nil" (i.e the string) @@ -547,6 +543,10 @@ If COLLECTION is an `obarray', a TEST should be needed. See `obarray'." do (setq cands (delete d cands)) when str collect str) cands)) + ((and (not (equal default "")) + (string= helm-pattern "")) + (cons default (delete (helm-stringify default) + cands))) (t cands)))) ;;;###autoload