fix notification setup (not tested)

This commit is contained in:
2023-11-08 14:33:02 +01:00
parent 3fa56b6463
commit 5fec1d67d6

View File

@@ -14,7 +14,11 @@ else{
//Ask for notifications permission on page load
window.addEventListener('load', function() {
if (Notification.permission !== "granted") {
Notification.requestPermission();
Notification.requestPermission().then(r => {
if(r !== "granted"){
console.error("Permission de notification refusée");
}
});
}
});
}