Fix possible crash in inconsistent HistoryWidget state.
This commit is contained in:
parent
31ba2828af
commit
8c6b5caa57
|
@ -1769,6 +1769,7 @@ void HistoryWidget::showHistory(
|
|||
|
||||
_showAtMsgId = showAtMsgId;
|
||||
_historyInited = false;
|
||||
_contactStatus = nullptr;
|
||||
|
||||
// Unload lottie animations.
|
||||
Auth().data().unloadHeavyViewParts(HistoryInner::ElementDelegate());
|
||||
|
@ -1786,8 +1787,6 @@ void HistoryWidget::showHistory(
|
|||
}, _contactStatus->lifetime());
|
||||
orderWidgets();
|
||||
controller()->tabbedSelector()->setCurrentPeer(_peer);
|
||||
} else {
|
||||
_contactStatus = nullptr;
|
||||
}
|
||||
refreshTabbedPanel();
|
||||
|
||||
|
|
Loading…
Reference in New Issue