summaryrefslogtreecommitdiff
path: root/helm-lib.el
diff options
context:
space:
mode:
authorThierry Volpiatto <thierry.volpiatto@gmail.com>2019-12-14 06:50:54 +0100
committerThierry Volpiatto <thierry.volpiatto@gmail.com>2019-12-14 06:50:54 +0100
commit82ae939caa211440cf5c2f7976b439901d3f0cd5 (patch)
treeb407ce1d29356d801b0bd8d3b6e4c6b2e3197f20 /helm-lib.el
parent4c692c3e537225794522066e1975bb41360f2642 (diff)
No sort when empty string
Diffstat (limited to 'helm-lib.el')
-rw-r--r--helm-lib.el4
1 files changed, 3 insertions, 1 deletions
diff --git a/helm-lib.el b/helm-lib.el
index b8901d41..dfc26002 100644
--- a/helm-lib.el
+++ b/helm-lib.el
@@ -1439,7 +1439,9 @@ specified in `helm-completion-styles-alist'."
(when (cdr last-data)
(setcdr last-data nil))
(setq all (copy-sequence comps))
- (if sort-fn (funcall sort-fn all) all)))))
+ (if (and sort-fn (> (length str) 0))
+ (funcall sort-fn all)
+ all)))))
;; Ensure circular objects are removed.
(complete-with-action t compsfn helm-pattern predicate))))