mirror of
https://github.com/AyuGram/AyuGramDesktop.git
synced 2025-04-16 14:17:12 +02:00
Fix a crash in topic deletion.
This commit is contained in:
parent
df8176d671
commit
77078f704c
1 changed files with 9 additions and 1 deletions
|
@ -1749,7 +1749,15 @@ void SessionController::showSection(
|
|||
}
|
||||
|
||||
void SessionController::showBackFromStack(const SectionShow ¶ms) {
|
||||
content()->showBackFromStack(params);
|
||||
const auto bad = [&] {
|
||||
// If we show a currently-being-destroyed topic, then
|
||||
// skip it and show back one more.
|
||||
const auto topic = _activeChatEntry.current().key.topic();
|
||||
return topic && topic->forum()->topicDeleted(topic->rootId());
|
||||
};
|
||||
do {
|
||||
content()->showBackFromStack(params);
|
||||
} while (bad());
|
||||
}
|
||||
|
||||
void SessionController::showSpecialLayer(
|
||||
|
|
Loading…
Add table
Reference in a new issue