mirror of
https://github.com/danog/telegram-tt.git
synced 2024-11-27 04:45:08 +01:00
Fix Chat List: Copyrighted chats are not shown (#999)
This commit is contained in:
parent
2c27e16f0d
commit
580bca90e2
@ -121,9 +121,13 @@ function buildApiChatRestrictions(peerEntity: GramJs.TypeUser | GramJs.TypeChat)
|
||||
isRestricted: peerEntity.kicked,
|
||||
};
|
||||
} else if (peerEntity instanceof GramJs.Channel) {
|
||||
const isRestricted = peerEntity.restricted
|
||||
&& peerEntity.restrictionReason
|
||||
&& peerEntity.restrictionReason.some((reason) => reason.platform === 'all');
|
||||
|
||||
return {
|
||||
isNotJoined: peerEntity.left,
|
||||
isRestricted: peerEntity.restricted,
|
||||
isRestricted,
|
||||
restrictionReason: buildApiChatRestrictionReason(peerEntity.restrictionReason),
|
||||
};
|
||||
}
|
||||
|
Loading…
Reference in New Issue
Block a user