From bcbb9de669a5d98c436b7966919151b9dd039d47 Mon Sep 17 00:00:00 2001 From: Aevann Date: Wed, 9 Aug 2023 18:33:58 +0300 Subject: [PATCH] fix "enable push notifications" button not working in chat --- files/assets/js/core.js | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) diff --git a/files/assets/js/core.js b/files/assets/js/core.js index b8c43495a..1171031b4 100644 --- a/files/assets/js/core.js +++ b/files/assets/js/core.js @@ -486,7 +486,7 @@ function handle_files(input, newfiles) { if (input.files.length > 20) { - alert("You can't upload more than 20 files at one time!") + window.alert("You can't upload more than 20 files at one time!") input.value = null oldfiles[ta.id] = new DataTransfer(); return @@ -686,9 +686,9 @@ function enablePushNotifications() { }) }).then((subscription) => { updateSubscriptionOnServer(subscription, "/push_subscribe") - alert("Push notifications are enabled!") + window.alert("Push notifications are enabled!") }).catch((e) => { - alert("Please give the site access to notifications!") + window.alert("Please give the site access to notifications!") console.error(e) }) }