diff options
author | Yorhel <git@yorhel.nl> | 2020-02-13 18:50:36 +0100 |
---|---|---|
committer | Yorhel <git@yorhel.nl> | 2020-02-13 18:50:36 +0100 |
commit | c4b43c9175650ee19f27c1f400660dd926f389b8 (patch) | |
tree | adf82137fd2eebaf178f84716dc7ae2e2c4a456a /elm | |
parent | dac3f16d9e8960c80077dc4d46cfad0747427af7 (diff) |
Lib.Autocomplete: Don't try to autocomplete whitespace
Diffstat (limited to 'elm')
-rw-r--r-- | elm/Lib/Autocomplete.elm | 2 |
1 files changed, 1 insertions, 1 deletions
diff --git a/elm/Lib/Autocomplete.elm b/elm/Lib/Autocomplete.elm index ec82bc12..2e321a87 100644 --- a/elm/Lib/Autocomplete.elm +++ b/elm/Lib/Autocomplete.elm @@ -173,7 +173,7 @@ update cfg msg model = Key _ -> mod model Input s -> - if s == "" + if String.trim s == "" then mod { model | value = s, loading = False, results = [] } else ( { model | value = s, loading = True, wait = model.wait + 1 } , Task.perform (always <| cfg.wrap <| Search <| model.wait + 1) (Process.sleep 500) |