branch: elpa/helm commit 6743929b409f01296d33178593e1eacf57b53828 Author: Thierry Volpiatto <thie...@posteo.net> Commit: Thierry Volpiatto <thie...@posteo.net>
Simplify default value of pattern in helm-mm* --- helm-multi-match.el | 6 ++---- 1 file changed, 2 insertions(+), 4 deletions(-) diff --git a/helm-multi-match.el b/helm-multi-match.el index eeaa2ac09d..e32a9978d9 100644 --- a/helm-multi-match.el +++ b/helm-multi-match.el @@ -210,8 +210,7 @@ E.g., \"foo bar\"=>((identity . \"foo\") (identity . \"bar\")). Then each predicate of cons cell(s) is called with the regexp of the same cons cell against CANDIDATE. I.e. (identity (string-match \"foo\" \"foo bar\")) => t." - (unless pattern (setq pattern helm-pattern)) - (let ((pat (helm-mm-3-get-patterns pattern))) + (let ((pat (helm-mm-3-get-patterns (or pattern helm-pattern)))) (cl-loop for (predicate . regexp) in pat for re = (if (and helm-mm--match-on-diacritics (not (helm-mm-regexp-p regexp))) @@ -301,8 +300,7 @@ CANDIDATE starting at end of first match." ;; just the files we want e.g. with a pattern like "/home/you/github/ foo git" ;; you would match all files of directory instead of matching only ;; "/home/you/github/foo-git.el" because "git" will always match "github". - (unless pattern (setq pattern helm-pattern)) - (let ((pat (helm-mm-3-get-patterns pattern))) + (let ((pat (helm-mm-3-get-patterns (or pattern helm-pattern)))) (cl-loop with end = nil for (predicate . regexp) in pat for re = (if (and helm-mm--match-on-diacritics