Keep privacy exception flag when hiding action bar and reporting spam.
GitOrigin-RevId: 64c21e3ca52bf74b19b7ee40bee6c9218a6feb70
This commit is contained in:
parent
de069fef3f
commit
4ae36f6564
@ -454,7 +454,7 @@ supergroup id:int32 username:string date:int32 status:ChatMemberStatus member_co
|
||||
//@banned_count Number of users banned from chat; 0 if unknown
|
||||
//@linked_chat_id Chat identifier of a discussion group for the channel, or a channel, for which the supergroup is a discussion group; 0 if none or unknown
|
||||
//@can_get_members True, if members of the chat can be retrieved
|
||||
//@can_set_username True, if the chat can have username
|
||||
//@can_set_username True, if the chat username can be changed
|
||||
//@can_set_sticker_set True, if the supergroup sticker set can be changed
|
||||
//@can_set_location True, if the supergroup location can be changed
|
||||
//@can_view_statistics True, if the channel statistics is available through getChatStatisticsUrl
|
||||
|
@ -3247,7 +3247,8 @@ class UpdatePeerSettingsQuery : public Td::ResultHandler {
|
||||
td->messages_manager_->on_get_peer_settings(
|
||||
dialog_id_,
|
||||
make_tl_object<telegram_api::peerSettings>(0, false /*ignored*/, false /*ignored*/, false /*ignored*/,
|
||||
false /*ignored*/, false /*ignored*/, false /*ignored*/));
|
||||
false /*ignored*/, false /*ignored*/, false /*ignored*/),
|
||||
true);
|
||||
|
||||
promise_.set_value(Unit());
|
||||
}
|
||||
@ -3288,7 +3289,8 @@ class ReportEncryptedSpamQuery : public Td::ResultHandler {
|
||||
td->messages_manager_->on_get_peer_settings(
|
||||
dialog_id_,
|
||||
make_tl_object<telegram_api::peerSettings>(0, false /*ignored*/, false /*ignored*/, false /*ignored*/,
|
||||
false /*ignored*/, false /*ignored*/, false /*ignored*/));
|
||||
false /*ignored*/, false /*ignored*/, false /*ignored*/),
|
||||
true);
|
||||
|
||||
promise_.set_value(Unit());
|
||||
}
|
||||
@ -6691,9 +6693,10 @@ void MessagesManager::report_dialog(DialogId dialog_id, const tl_object_ptr<td_a
|
||||
}
|
||||
|
||||
void MessagesManager::on_get_peer_settings(DialogId dialog_id,
|
||||
tl_object_ptr<telegram_api::peerSettings> &&peer_settings) {
|
||||
tl_object_ptr<telegram_api::peerSettings> &&peer_settings,
|
||||
bool ignore_privacy_exception) {
|
||||
CHECK(peer_settings != nullptr);
|
||||
if (dialog_id.get_type() == DialogType::User) {
|
||||
if (dialog_id.get_type() == DialogType::User && !ignore_privacy_exception) {
|
||||
auto need_phone_number_privacy_exception =
|
||||
(peer_settings->flags_ & telegram_api::peerSettings::NEED_CONTACTS_EXCEPTION_MASK) != 0;
|
||||
td_->contacts_manager_->on_update_user_need_phone_number_privacy_exception(dialog_id.get_user_id(),
|
||||
|
@ -673,7 +673,8 @@ class MessagesManager : public Actor {
|
||||
void report_dialog(DialogId dialog_id, const tl_object_ptr<td_api::ChatReportReason> &reason,
|
||||
const vector<MessageId> &message_ids, Promise<Unit> &&promise);
|
||||
|
||||
void on_get_peer_settings(DialogId dialog_id, tl_object_ptr<telegram_api::peerSettings> &&peer_settings);
|
||||
void on_get_peer_settings(DialogId dialog_id, tl_object_ptr<telegram_api::peerSettings> &&peer_settings,
|
||||
bool ignore_privacy_exception = false);
|
||||
|
||||
void get_dialog_statistics_url(DialogId dialog_id, const string ¶meters, bool is_dark,
|
||||
Promise<td_api::object_ptr<td_api::httpUrl>> &&promise);
|
||||
|
Reference in New Issue
Block a user