-
Notifications
You must be signed in to change notification settings - Fork 893
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
Match exact host in autoplay whitelist before matching eTLD+1 #4741
Conversation
@@ -32,6 +32,12 @@ AutoplayWhitelistService::~AutoplayWhitelistService() { | |||
|
|||
bool AutoplayWhitelistService::ShouldAllowAutoplay(const GURL& url) { | |||
DCHECK_CALLED_ON_VALID_SEQUENCE(sequence_checker_); | |||
// look for exact host match (this is the only way that subdomains | |||
// listed in the autoplay whitelist will match) | |||
if (url.has_host() && |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
looks right to me, but will wait for confirmation that it works. A couple of unit tests would be super too.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
simplified the test data file and added multiple tests
70dbf83
to
31feca2
Compare
AFAICT this only failed because of Github's connectivity issues yesterday, but I'll rebase it and run it through again just to be sure. |
31feca2
to
e7c2198
Compare
Added missing milestone to this PR and brave/brave-browser#4621 |
uplifted to release |
Reproduced the original issue on
Verification PASSED on
|
Moving this out of https://github.com/brave/brave-core/milestone/56 as this specific PR is on |
Resolves brave/brave-browser#4621
Submitter Checklist:
npm run lint
)git rebase master
(if needed).git rebase -i
to squash commits (if needed).Test Plan:
Reviewer Checklist:
After-merge Checklist:
changes has landed on.