From 70e542c9cc587d66363875ac3ec612ae3ebb0aab Mon Sep 17 00:00:00 2001 From: Evy Kassirer Date: Thu, 27 Mar 2025 14:43:38 -0700 Subject: [PATCH] buddy_list: Make sure we always open Others section during search. --- web/src/buddy_list.ts | 15 +++++---------- 1 file changed, 5 insertions(+), 10 deletions(-) diff --git a/web/src/buddy_list.ts b/web/src/buddy_list.ts index 11907e4d80..8f85296019 100644 --- a/web/src/buddy_list.ts +++ b/web/src/buddy_list.ts @@ -310,21 +310,16 @@ export class BuddyList extends BuddyListConf { "#buddy-list-users-matching-view-container", this.users_matching_view_is_collapsed, ); + // Ensure the "other" section is visible when headers are collapsed, + // because we're hiding its header so there's no way to collapse or + // uncollapse the list in this view. Ensure we're showing/hiding as + // the user specified otherwise. this.set_section_collapse( "#buddy-list-other-users-container", - this.other_users_is_collapsed, + this.render_data.hide_headers ? false : this.other_users_is_collapsed, ); } - // Ensure the "other" section is visible when headers are collapsed, - // because we're hiding its header so there's no way to collapse or - // uncollapse the list in this view. Ensure we're showing/hiding as - // the user specified otherwise. - this.set_section_collapse( - "#buddy-list-other-users-container", - this.render_data.hide_headers ? false : this.other_users_is_collapsed, - ); - this.fill_screen_with_content(); // This must happen after `fill_screen_with_content`