From 7509be7cba8c7d4d269a43cd3d7e9d76f04f39bc Mon Sep 17 00:00:00 2001 From: Paco <> Date: Wed, 13 Jan 2021 15:46:36 +0100 Subject: [PATCH] `Notification not defined` fix #192 (may fix #224) --- themes/default/public/js/lufi-notifications.js | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/themes/default/public/js/lufi-notifications.js b/themes/default/public/js/lufi-notifications.js index d198df6..d0cd504 100644 --- a/themes/default/public/js/lufi-notifications.js +++ b/themes/default/public/js/lufi-notifications.js @@ -1,5 +1,5 @@ function notify(title, body) { - if (!Notification) { + if (!'Notification' in window) { console.log("This browser does not support desktop notification, cannot send following message: "+title+" "+body); return; } @@ -16,7 +16,7 @@ function notify(title, body) { } document.addEventListener('DOMContentLoaded', function () { - if (!Notification) { + if (!'Notification' in window) { return; }