No "Who Viewed" in case of hidden members.

This commit is contained in:
John Preston 2022-12-23 14:32:46 +04:00
parent b9b6d4dba1
commit bd490421e8
1 changed files with 4 additions and 1 deletions

View File

@ -571,7 +571,10 @@ bool WhoReadExists(not_null<HistoryItem*> item) {
const auto peer = history->peer;
const auto chat = peer->asChat();
const auto megagroup = peer->asMegagroup();
if ((!chat && !megagroup) || peer->isForum()) {
if ((!chat && !megagroup)
|| peer->isForum()
|| (megagroup
&& (megagroup->flags() & ChannelDataFlag::ParticipantsHidden))) {
return false;
}
const auto &appConfig = peer->session().account().appConfig();