Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Does not clean URL on Google's sites #151

Closed
RepoMoveBot opened this issue Jul 12, 2018 · 5 comments · Fixed by #209
Closed

Does not clean URL on Google's sites #151

RepoMoveBot opened this issue Jul 12, 2018 · 5 comments · Fixed by #209

Comments

@RepoMoveBot
Copy link

Issue by hayohayo
Tuesday Jul 03, 2018 at 18:35 GMT


Neat URL does not delete query parameters from links on Google. The simplest URL that reproduces my issue is: https://www.google.com/?utm_source=x. utm_source is removed just fine on other domains.

Add-on: Neat URL 4.1.5
OS: MacOS High Sierra
Browser: Firefox 61.0

@RepoMoveBot
Copy link
Author

Comment by hayohayo
Tuesday Jul 03, 2018 at 18:46 GMT


I believe, it has something to do with domain-specific blocked parameters. Once I've removed ved@google.*, ei@google.*, sei@google.*, gws_rd@google.*, utm_source is properly removed.

@RepoMoveBot
Copy link
Author

Comment by crssi
Tuesday Jul 03, 2018 at 20:22 GMT


It must be different on MacOS then on Windows 10, since here is working fine.
This is from browser console:
[Neat URL]: (type main_frame): 'https://www.google.com/?utm_source=x' has been changed to 'https://www.google.com/'

@RepoMoveBot
Copy link
Author

Comment by hayohayo
Tuesday Jul 03, 2018 at 20:39 GMT


Hmm... have just tried on Debian - the same here. Works for, say, amazon.com, but not on google.com. Also, not sure how to see the logs - I don't see them in browser's console, even though I enabled them in add-on's settings.

OS: Linux, Debian 9.4
Browser: Firefox ESR 52.9.0

@RepoMoveBot RepoMoveBot changed the title [Neat URL] Does not clean URL on Google's sites Does not clean URL on Google's sites Jul 12, 2018
@my-wan
Copy link

my-wan commented Jul 21, 2018

Had the same issue on Lubuntu 17.10 (32 bit) LXDE with Firefox 61.0. Removing gws_rd@google.* by itself from the blocked parameters fixed the issue. However, setting gws_rd as a global block does not cause any problems, only when given as a Google specific block. This appears related to the workaround for issue# 76 on line 288 of background.js. The only thing that's returning true even when it apparently shouldn't is detailsUrl.contains("gws_rd=cr"). There is no gws_rd parameter in the Google URLS being skipped. I haven't got deep enough to know why yet. But this appears to be where the getMatch function is returning prematurely and skipping the Google domain when it shouldn't.

@tartpvule
Copy link

Duplicate: #146

This is a bug in 53eb44b, specifically the one in background.js supposedly for fixing #76, like @my-wan said.
But the problem is not that it returns true, it is that throws detailsUrl.contains is not a function.

In background.js line 501, let match = getMatch(gbp, domain, rootDomain, domainMinusSuffix, url);.
"url" here is a URL object, not a string.

The end result is that the presence of "gws_rd@google.*" in "Blocked parameters" causes Neat URL to not process google.com URLs altogether.

Please fix this.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging a pull request may close this issue.

3 participants