mirror of https://github.com/zulip/zulip.git
server_events_dispatch: Fix stream archived booked not displayed.
Fixed by updating bookend after stream data is deleted. When a stream is deleted and user is narrowed to the stream, stream archived bookend is now displayed correctly.
This commit is contained in:
parent
933195f7a5
commit
8f0a0af588
|
@ -553,10 +553,6 @@ export function dispatch_normal_event(event) {
|
||||||
const is_narrowed_to_stream = narrow_state.is_for_stream_id(
|
const is_narrowed_to_stream = narrow_state.is_for_stream_id(
|
||||||
stream.stream_id,
|
stream.stream_id,
|
||||||
);
|
);
|
||||||
if (is_narrowed_to_stream) {
|
|
||||||
assert(message_lists.current !== undefined);
|
|
||||||
message_lists.current.update_trailing_bookend(true);
|
|
||||||
}
|
|
||||||
stream_data.delete_sub(stream.stream_id);
|
stream_data.delete_sub(stream.stream_id);
|
||||||
stream_settings_ui.remove_stream(stream.stream_id);
|
stream_settings_ui.remove_stream(stream.stream_id);
|
||||||
if (was_subscribed) {
|
if (was_subscribed) {
|
||||||
|
@ -582,6 +578,10 @@ export function dispatch_normal_event(event) {
|
||||||
"zulip_update_announcements_stream_id",
|
"zulip_update_announcements_stream_id",
|
||||||
);
|
);
|
||||||
}
|
}
|
||||||
|
if (is_narrowed_to_stream) {
|
||||||
|
assert(message_lists.current !== undefined);
|
||||||
|
message_lists.current.update_trailing_bookend(true);
|
||||||
|
}
|
||||||
}
|
}
|
||||||
stream_list.update_subscribe_to_more_streams_link();
|
stream_list.update_subscribe_to_more_streams_link();
|
||||||
break;
|
break;
|
||||||
|
|
Loading…
Reference in New Issue