aboutsummaryrefslogtreecommitdiff
path: root/javascript/notification.js
diff options
context:
space:
mode:
authorAUTOMATIC1111 <16777216c@gmail.com>2023-05-17 23:18:56 +0300
committerGitHub <noreply@github.com>2023-05-17 23:18:56 +0300
commit04b4508a66de58c9f3a422fdcad4dd2ec3ad39ce (patch)
tree1cb30a63099a69f678d4901b495203b765a6df59 /javascript/notification.js
parent7201d940a4fe664beb9662fadbeade4ee1d788f7 (diff)
parentb397f63e00bbfbe9087d80abb457aa9a593b181b (diff)
Merge branch 'dev' into improve-frontend-responsiveness
Diffstat (limited to 'javascript/notification.js')
-rw-r--r--javascript/notification.js6
1 files changed, 3 insertions, 3 deletions
diff --git a/javascript/notification.js b/javascript/notification.js
index 8ddd4c5d..83fce1f8 100644
--- a/javascript/notification.js
+++ b/javascript/notification.js
@@ -2,15 +2,15 @@
let lastHeadImg = null;
-notificationButton = null
+let notificationButton = null;
onUiUpdate(function(){
if(notificationButton == null){
notificationButton = gradioApp().getElementById('request_notifications')
if(notificationButton != null){
- notificationButton.addEventListener('click', function (evt) {
- Notification.requestPermission();
+ notificationButton.addEventListener('click', () => {
+ void Notification.requestPermission();
},true);
}
}