mirror of
https://github.com/zulip/zulip.git
synced 2025-11-06 15:03:34 +00:00
Don't show in-app notifications if stream desktop notifications are disabled.
(imported from commit efa29afaa40b65557149ea8a2cbc60e1bc44bee2)
This commit is contained in:
@@ -430,12 +430,13 @@ exports.received_messages = function (messages) {
|
|||||||
|
|
||||||
message.notification_sent = true;
|
message.notification_sent = true;
|
||||||
|
|
||||||
if (should_send_desktop_notification(message) &&
|
if (should_send_desktop_notification(message)) {
|
||||||
browser_desktop_notifications_on()) {
|
if (browser_desktop_notifications_on()) {
|
||||||
process_notification({message: message, webkit_notify: true});
|
process_notification({message: message, webkit_notify: true});
|
||||||
} else {
|
} else {
|
||||||
process_notification({message: message, webkit_notify: false});
|
process_notification({message: message, webkit_notify: false});
|
||||||
}
|
}
|
||||||
|
}
|
||||||
if (should_send_audible_notification(message) && supports_sound) {
|
if (should_send_audible_notification(message) && supports_sound) {
|
||||||
if (window.bridge !== undefined) {
|
if (window.bridge !== undefined) {
|
||||||
window.bridge.bell();
|
window.bridge.bell();
|
||||||
|
|||||||
Reference in New Issue
Block a user