Update permanent invite link after it is revoked.

This commit is contained in:
levlam 2021-02-05 19:23:29 +03:00
parent 4cb8af0584
commit f46ff6e1cd

View File

@ -1910,6 +1910,10 @@ class RevokeChatInviteLinkQuery : public Td::ResultHandler {
if (!invite_link.is_valid() || !new_invite_link.is_valid()) { if (!invite_link.is_valid() || !new_invite_link.is_valid()) {
return on_error(id, Status::Error(500, "Receive invalid invite link")); return on_error(id, Status::Error(500, "Receive invalid invite link"));
} }
if (new_invite_link.get_administrator_user_id() == td->contacts_manager_->get_my_id() &&
new_invite_link.is_permanent()) {
td->contacts_manager_->on_get_permanent_dialog_invite_link(dialog_id_, new_invite_link);
}
links.push_back(invite_link.get_chat_invite_link_object(td->contacts_manager_.get())); links.push_back(invite_link.get_chat_invite_link_object(td->contacts_manager_.get()));
links.push_back(new_invite_link.get_chat_invite_link_object(td->contacts_manager_.get())); links.push_back(new_invite_link.get_chat_invite_link_object(td->contacts_manager_.get()));
break; break;