settings: Fix push notifications tooltip being incorrectly shown.

We were showing the push notifications tooltip in user default
settings section even if the push notifications were configured
on the server.

The bug was because the setting value was undefined in the template
used for user default settings section, so this commit fixes the bug
by correctly passing the setting value to relevant template file.

Fixes #21602.
This commit is contained in:
Sahil Batra
2022-03-30 15:09:21 +05:30
committed by Tim Abbott
parent 0008a76703
commit ca38b33346
3 changed files with 3 additions and 1 deletions

View File

@@ -161,6 +161,7 @@ export function build_page() {
settings_config.create_web_public_stream_policy_values,
disable_enable_spectator_access_setting: !page_params.server_web_public_streams_enabled,
can_sort_by_email: settings_data.show_email(),
realm_push_notifications_enabled: page_params.realm_push_notifications_enabled,
};
if (options.realm_logo_source !== "D" && options.realm_night_logo_source === "D") {