philc/vimium — pull request #1227 by smblott-github (2014-11-06 06:46:22+00:00)
Title: Suppress non-domain "domain" suggestions

Fixes #1224.

The domain completer should not generate suggestions for history entries which are not domains.

Even with this fix, there are anomalies in how domain suggestions are handled:
- A history entry `ftp://ftp.debian.org` results in a domain suggestion which resolves to `http://ftp.debian.org`.
- A history entry `https://secure.org` results in a domain suggestion which resolves to `http://secure.org`.

This happens because the domain completer [strips](https://github.com/philc/vimium/blob/master/background_scripts/completion.coffee#L241) the scheme from the URL. Then, when a URL is later [created](https://github.com/philc/vimium/blob/master/lib/utils.coffee#L37), `http://` is prepended.

We should fix this too.