Fix inversion of audio notification preference

This commit is contained in:
Evan Hahn 2021-09-24 15:11:16 -05:00 committed by GitHub
parent 1c3c971cf4
commit 47634acc3d
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23
1 changed files with 5 additions and 1 deletions

View File

@ -232,6 +232,10 @@ class NotificationService extends EventEmitter {
return;
}
const shouldPlayNotificationSound = Boolean(
storage.get('audio-notification')
);
const shouldDrawAttention = storage.get(
'notification-draw-attention',
true
@ -304,7 +308,7 @@ class NotificationService extends EventEmitter {
title: notificationTitle,
icon: notificationIconUrl,
message: notificationMessage,
silent: Boolean(storage.get('audio-notification')),
silent: !shouldPlayNotificationSound,
onNotificationClick: () => {
this.emit('click', conversationId, messageId);
},