Skip to content
GitLab
Menu
Projects
Groups
Snippets
/
Help
Help
Support
Community forum
Keyboard shortcuts
?
Submit feedback
Contribute to GitLab
Sign in
Toggle navigation
Menu
Open sidebar
The Tor Project
Applications
Tor Browser
Commits
5c21edce
Commit
5c21edce
authored
May 19, 2022
by
Nika Layzell
Committed by
Richard Pospesel
May 20, 2022
Browse files
Bug 1770137 - Part 2, r=Gijs, a=dsmith
Differential Revision:
https://phabricator.services.mozilla.com/D146851
parent
e89fa5db
Changes
1
Hide whitespace changes
Inline
Side-by-side
dom/notification/old/NotificationDB.jsm
View file @
5c21edce
...
...
@@ -75,13 +75,14 @@ var NotificationDB = {
},
filterNonAppNotifications(notifications) {
let result = Object.create(null);
for (let origin in notifications) {
result[origin] = Object.create(null);
let persistentNotificationCount = 0;
for (let id in notifications[origin]) {
if (notifications[origin][id].serviceWorkerRegistrationScope) {
persistentNotificationCount++;
} else {
delete notifications[origin][id];
result[origin][id] = notifications[origin][id];
}
}
if (persistentNotificationCount == 0) {
...
...
@@ -90,11 +91,11 @@ var NotificationDB = {
"Origin " + origin + " is not linked to an app manifest, deleting."
);
}
delete
notifications
[origin];
delete
result
[origin];
}
}
return
notifications
;
return
result
;
},
// Attempt to read notification file, if it's not there we will create it.
...
...
Write
Preview
Supports
Markdown
0%
Try again
or
attach a new file
.
Attach a file
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Cancel
Please
register
or
sign in
to comment