[FIX] Opening search field after server list does not hide server list (#4792)

* [FIX] Opening search field after server list does not hide server list

* minor tweak
This commit is contained in:
Reinaldo Neto 2023-01-06 12:36:23 -03:00 committed by Diego Mello
parent c6314ea9a2
commit 275c3a9e36
1 changed files with 4 additions and 1 deletions

View File

@ -593,8 +593,11 @@ class RoomsListView extends React.Component<IRoomsListViewProps, IRoomsListViewS
initSearching = () => {
logEvent(events.RL_SEARCH);
const { dispatch } = this.props;
const { dispatch, showServerDropdown } = this.props;
this.internalSetState({ searching: true }, () => {
if (showServerDropdown) {
dispatch(closeServerDropdown());
}
dispatch(openSearchHeader());
this.handleSearch('');
this.setHeader();