2
0
mirror of https://github.com/telegramdesktop/tdesktop synced 2025-08-31 22:46:10 +00:00

Fix new window crash for unavailable channels.

This commit is contained in:
John Preston
2022-06-22 15:30:56 +04:00
parent e2624416af
commit d81c40f4c8
6 changed files with 32 additions and 12 deletions

View File

@@ -263,7 +263,7 @@ Widget::Widget(
const auto showAtMsgId = controller->uniqueChatsInSearchResults()
? ShowAtUnreadMsgId
: row.message.fullId.msg;
if (row.newWindow) {
if (row.newWindow && controller->canShowSeparateWindow(peer)) {
const auto active = controller->activeChatCurrent();
if (const auto history = active.history()) {
if (history->peer == peer) {