MCPcopy Create free account
hub / github.com/TDesktop-x64/tdesktop / canCreateTopics

Method canCreateTopics

Telegram/SourceFiles/data/data_peer.cpp:730–738  ·  view source on GitHub ↗

Source from the content-addressed store, hash-verified

728}
729
730bool PeerData::canCreateTopics() const {
731 if (const auto bot = asBot()) {
732 return bot->isForum();
733 } else if (const auto channel = asChannel()) {
734 return channel->isForum()
735 && !channel->amRestricted(ChatRestriction::CreateTopics);
736 }
737 return false;
738}
739
740bool PeerData::canManageTopics() const {
741 if (const auto bot = asBot()) {

Callers 2

addCreateTopicMethod · 0.80
ForumMethod · 0.80

Calls 2

amRestrictedMethod · 0.80
isForumMethod · 0.45

Tested by

no test coverage detected