Bug 1803268 - Minor clean-up in nsScreen::ShouldResistFingerprinting(). r=smaug
This doesn't change behavior but it's cleaner, and while I was near that code... Differential Revision: https://phabricator.services.mozilla.com/D163505
This commit is contained in:
@@ -224,10 +224,7 @@ nsresult nsScreen::GetWindowInnerRect(CSSIntRect& aRect) {
|
||||
}
|
||||
|
||||
bool nsScreen::ShouldResistFingerprinting() const {
|
||||
bool resist = false;
|
||||
nsCOMPtr<nsPIDOMWindowInner> owner = GetOwner();
|
||||
if (owner) {
|
||||
resist = nsContentUtils::ShouldResistFingerprinting(owner->GetDocShell());
|
||||
}
|
||||
return resist;
|
||||
return owner &&
|
||||
nsGlobalWindowInner::Cast(owner)->ShouldResistFingerprinting();
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user