Improved blocked but required capability reporting from subframes (issue #367).

This commit is contained in:
hackademix 2024-07-07 22:53:25 +02:00
parent 46808f3125
commit 094c1ba6e4
No known key found for this signature in database
GPG Key ID: 231A83AFDA9C2434
1 changed files with 7 additions and 0 deletions

View File

@ -236,6 +236,13 @@ var RequestGuard = (() => {
async pageshow(message, sender) {
if (sender.frameId === 0) {
TabStatus.recordAll(sender.tab.id, message.seen);
} else {
// merge subframes records back into main frame's seen report
const tabId = sender.tab.id;
for (const {request, allowed, policyType} of message.seen) {
request.tabId = tabId;
Content.reportTo(request, allowed, policyType);
}
}
return true;
},