mirror of https://github.com/zulip/zulip.git
streams: Redirect to subscribed-tab on unsubscription for guest user.
This commit add code to redirect guest users to subscribed-stream-tab and removes the recently-unsubscribed stream from settings tab on unsubscription.
This commit is contained in:
parent
b68c1bb6ac
commit
3f38fc6b79
|
@ -106,7 +106,7 @@ exports.update_stream_row_in_settings_tab = function (sub) {
|
|||
var sub_row = subs.row_for_stream_id(sub.stream_id);
|
||||
if (sub.subscribed) {
|
||||
sub_row.removeClass("notdisplayed");
|
||||
} else if (sub.invite_only) {
|
||||
} else if (sub.invite_only || page_params.is_guest) {
|
||||
sub_row.addClass("notdisplayed");
|
||||
}
|
||||
}
|
||||
|
|
|
@ -320,6 +320,9 @@ exports.update_settings_for_unsubscribed = function (sub) {
|
|||
if (!sub.should_display_subscription_button) {
|
||||
stream_ui_updates.update_add_subscriptions_elements(sub);
|
||||
}
|
||||
if (page_params.is_guest) {
|
||||
stream_edit.open_edit_panel_empty();
|
||||
}
|
||||
|
||||
// Remove private streams from subscribed streams list.
|
||||
stream_ui_updates.update_stream_row_in_settings_tab(sub);
|
||||
|
|
Loading…
Reference in New Issue