about:torconnect new url location override (maybeUpdateOpenLocationForTorConnect) mostly does nothing
We have a method called maybeUpdateOpenLocationForTorConnect
and I think the idea is that if the user's current tab is "about:torconnect" and then types in the urlbar "about:preferences" or "example.org", etc, it will be opened in a new tab instead of the current tab.
I was able to trace this feature back to !158 (merged), but I'm not sure which of the issues this was meant to address.
However, since "about:torconnect" nearly always has a redirect query in its url, including at startup where it redirects to "about:tor", this part of the logic won't match the real "about:torconnect" url. As such, most of the time this method will do nothing. The only scenario I can think of where it would work as intended is when the user types "about:torconnect" exactly into the url bar.
It can be easily fixed by stripping out the query from the current url. But I'm not sure if UX would rather we just drop this feature given the updates we have had in the mean time.
Note:
- We now have the "Connect" button in the url bar.
- Most firefox UI will open "about:" pages in a new tab. Unless the user types the "about:" url in the url bar directly.
- If the user tries to visit a web page, it will redirect to "about:torconnect" after hitting a neterror anyway. With the intended behaviour, this would open up two "about:torconnect" pages, one of which will resolve to the home page ("about:tor"), the other will resolve to the web page. If we drop this, then we just have one "about:torconnect" page that redirects to the web page.
/cc @donuts