diff --git a/frontend_tests/node_tests/i18n.js b/frontend_tests/node_tests/i18n.js index f29487f584..348c7ae240 100644 --- a/frontend_tests/node_tests/i18n.js +++ b/frontend_tests/node_tests/i18n.js @@ -49,7 +49,7 @@ i18n.init({ avatar_url: "http://example.com", left_side_userlist: false, twenty_four_hour_time: false, - stream_desktop_notifications_enabled: false, + enable_stream_desktop_notifications: false, enable_stream_sounds: false, desktop_notifications_enabled: false, enable_sounds: false, diff --git a/frontend_tests/node_tests/templates.js b/frontend_tests/node_tests/templates.js index 47d08296a1..87d2798487 100644 --- a/frontend_tests/node_tests/templates.js +++ b/frontend_tests/node_tests/templates.js @@ -779,7 +779,7 @@ function render(template_name, args) { (function settings_tab() { var page_param_checkbox_options = { - stream_desktop_notifications_enabled: true, + enable_stream_desktop_notifications: true, enable_stream_sounds: true, desktop_notifications_enabled: true, enable_sounds: true, enable_offline_email_notifications: true, enable_offline_push_notifications: true, enable_online_push_notifications: true, diff --git a/static/js/notifications.js b/static/js/notifications.js index fe0fa37ebf..f17fed9293 100644 --- a/static/js/notifications.js +++ b/static/js/notifications.js @@ -636,7 +636,7 @@ exports.handle_global_notification_updates = function (notification_name, settin // for a given message. These settings do not affect whether or not a // particular stream should receive notifications. if (notification_name === "enable_stream_desktop_notifications") { - page_params.stream_desktop_notifications_enabled = setting; + page_params.enable_stream_desktop_notifications = setting; } else if (notification_name === "enable_stream_sounds") { page_params.enable_stream_sounds = setting; } else if (notification_name === "enable_desktop_notifications") { diff --git a/static/js/settings_notifications.js b/static/js/settings_notifications.js index 53729fb73a..b21cac8c65 100644 --- a/static/js/settings_notifications.js +++ b/static/js/settings_notifications.js @@ -16,7 +16,7 @@ exports.set_up = function () { // Stream notification settings. if (result.enable_stream_desktop_notifications !== undefined) { - page_params.stream_desktop_notifications_enabled = + page_params.enable_stream_desktop_notifications = result.enable_stream_desktop_notifications; } if (result.enable_stream_sounds !== undefined) { @@ -142,7 +142,7 @@ exports.set_up = function () { }; function _update_page() { - $("#enable_stream_desktop_notifications").prop('checked', page_params.stream_desktop_notifications_enabled); + $("#enable_stream_desktop_notifications").prop('checked', page_params.enable_stream_desktop_notifications); $("#enable_stream_sounds").prop('checked', page_params.enable_stream_sounds); $("#enable_desktop_notifications").prop('checked', page_params.desktop_notifications_enabled); $("#enable_sounds").prop('checked', page_params.enable_sounds); diff --git a/static/js/stream_data.js b/static/js/stream_data.js index f87e67cffb..f2c66922b1 100644 --- a/static/js/stream_data.js +++ b/static/js/stream_data.js @@ -278,7 +278,7 @@ exports.create_sub_from_server_data = function (stream_name, attrs) { newly_subscribed: false, in_home_view: true, invite_only: false, - desktop_notifications: page_params.stream_desktop_notifications_enabled, + desktop_notifications: page_params.enable_stream_desktop_notifications, audible_notifications: page_params.enable_stream_sounds, description: '', }); diff --git a/static/templates/settings/notification-settings.handlebars b/static/templates/settings/notification-settings.handlebars index 1dce19bdff..4697aa1953 100644 --- a/static/templates/settings/notification-settings.handlebars +++ b/static/templates/settings/notification-settings.handlebars @@ -17,7 +17,7 @@