Fix crash with "Hide all chats" enabled
This commit is contained in:
parent
065e29af79
commit
b8a512a132
1 changed files with 5 additions and 1 deletions
|
|
@ -194,7 +194,11 @@ void FiltersMenu::refresh() {
|
|||
// so we have to restore it.
|
||||
_scroll.scrollToY(oldTop);
|
||||
const auto i = _filters.find(_activeFilterId);
|
||||
scrollToButton((i != end(_filters)) ? i->second : _all);
|
||||
if (i != end(_filters)) {
|
||||
scrollToButton(i->second);
|
||||
} else if (!cHideFilterAllChats()) {
|
||||
scrollToButton(_all);
|
||||
}
|
||||
|
||||
if (FiltersFirstLoad) {
|
||||
_session->setActiveChatsFilter(cDefaultFilterId());
|
||||
|
|
|
|||
Loading…
Add table
Reference in a new issue