diff --git a/qutebrowser/commands/parsers.py b/qutebrowser/commands/parsers.py index fabbc35ea..82e502339 100644 --- a/qutebrowser/commands/parsers.py +++ b/qutebrowser/commands/parsers.py @@ -240,4 +240,6 @@ def split_cmdline(text): parts = parser.parse(text) except NoSuchCommandError: parts = text.split(' ') + if text.endswith(' '): + parts.append('') return parts diff --git a/qutebrowser/widgets/completion.py b/qutebrowser/widgets/completion.py index f9f349f1b..aadd1ba02 100644 --- a/qutebrowser/widgets/completion.py +++ b/qutebrowser/widgets/completion.py @@ -220,8 +220,6 @@ class CompletionView(QTreeView): text = text.lstrip(':') parts = split_cmdline(text) - if text.endswith(' '): - parts.append('') model = self._get_new_completion(parts) if model != self._lastmodel: