Allow replying in monoforum while not in it.

This commit is contained in:
John Preston 2025-06-03 14:31:23 +04:00
parent f4582ddf36
commit d156de05a5
2 changed files with 2 additions and 7 deletions

View file

@ -2896,10 +2896,7 @@ bool History::shouldBeInChatList() const {
} else if (isPinnedDialog(FilterId())) { } else if (isPinnedDialog(FilterId())) {
return true; return true;
} else if (const auto channel = peer->asChannel()) { } else if (const auto channel = peer->asChannel()) {
if (channel->isMonoforum()) { if (!channel->amIn()) {
return !lastMessageKnown()
|| (lastMessage() != nullptr);
} else if (!channel->amIn()) {
return isTopPromoted(); return isTopPromoted();
} }
} else if (const auto chat = peer->asChat()) { } else if (const auto chat = peer->asChat()) {

View file

@ -4970,9 +4970,7 @@ bool CanSendReply(not_null<const HistoryItem*> item) {
return false; return false;
} else if (const auto channel = peer->asChannel()) { } else if (const auto channel = peer->asChannel()) {
if (const auto sublist = item->savedSublist()) { if (const auto sublist = item->savedSublist()) {
if (sublist->sublistPeer() == peer) { return (sublist->sublistPeer() != peer);
return false;
}
} }
return channel->amIn(); return channel->amIn();
} }