2
0
mirror of https://github.com/kotatogram/kotatogram-desktop synced 2025-09-02 23:55:12 +00:00

Improve topic three-dot menu.

This commit is contained in:
John Preston
2022-11-01 18:22:15 +04:00
parent 03c08ad95f
commit fba0f0c49b
4 changed files with 33 additions and 12 deletions

View File

@@ -223,6 +223,11 @@ bool ForumTopic::canWrite() const {
&& (!closed() || canToggleClosed());
}
bool ForumTopic::canSendPolls() const {
return canWrite()
&& !channel()->amRestricted(ChatRestriction::SendPolls);
}
bool ForumTopic::canEdit() const {
return my() || channel()->canManageTopics();
}