mirror of
https://github.com/Qz3rK/tdesktop.git
synced 2026-07-03 14:15:08 +02:00
Disable forwarding public polls to channels.
This commit is contained in:
@@ -1797,6 +1797,8 @@ https://github.com/telegramdesktop/tdesktop/blob/master/LEGAL
|
||||
"lng_restricted_send_inline_all" = "Posting inline content isn't allowed in this group.";
|
||||
"lng_restricted_send_polls_all" = "Posting polls isn't allowed in this group.";
|
||||
|
||||
"lng_restricted_send_public_polls" = "Sorry, public polls can't be forwarded to channels.";
|
||||
|
||||
"lng_exceptions_list_title" = "Exceptions";
|
||||
"lng_removed_list_title" = "Removed users";
|
||||
|
||||
|
||||
@@ -1302,6 +1302,9 @@ TextForMimeData MediaPoll::clipboardText() const {
|
||||
}
|
||||
|
||||
QString MediaPoll::errorTextForForward(not_null<PeerData*> peer) const {
|
||||
if (_poll->publicVotes() && peer->isChannel() && !peer->isMegagroup()) {
|
||||
return tr::lng_restricted_send_public_polls(tr::now);
|
||||
}
|
||||
return Data::RestrictionError(
|
||||
peer,
|
||||
ChatRestriction::f_send_polls
|
||||
|
||||
Reference in New Issue
Block a user