Inline last usage of MessagesManager::is_forward_info_sender_hidden.

This commit is contained in:
levlam 2023-10-09 21:27:14 +03:00
parent 21068870f0
commit 94f72a026c
2 changed files with 1 additions and 8 deletions

View File

@ -24026,7 +24026,7 @@ tl_object_ptr<td_api::message> MessagesManager::get_message_object(DialogId dial
// i.e. a message is incoming only if it's a forwarded message with known from_dialog_id or with a hidden sender
auto forward_info = m->forward_info.get();
is_outgoing = is_scheduled || forward_info == nullptr ||
(!forward_info->from_dialog_id.is_valid() && !is_forward_info_sender_hidden(forward_info));
(!forward_info->from_dialog_id.is_valid() && !forward_info->origin.is_sender_hidden());
}
double ttl_expires_in = m->ttl_expires_at != 0 ? clamp(m->ttl_expires_at - Time::now(), 1e-3, m->ttl - 1e-3) : 0.0;
@ -27396,11 +27396,6 @@ bool MessagesManager::can_set_game_score(DialogId dialog_id, const Message *m) c
return true;
}
bool MessagesManager::is_forward_info_sender_hidden(const MessageForwardInfo *forward_info) {
CHECK(forward_info != nullptr);
return forward_info->origin.is_sender_hidden();
}
unique_ptr<MessagesManager::MessageForwardInfo> MessagesManager::get_message_forward_info(
tl_object_ptr<telegram_api::messageFwdHeader> &&forward_header) {
if (forward_header == nullptr) {

View File

@ -2818,8 +2818,6 @@ class MessagesManager final : public Actor {
tl_object_ptr<telegram_api::InputPeer> get_send_message_as_input_peer(const Message *m) const;
static bool is_forward_info_sender_hidden(const MessageForwardInfo *forward_info);
unique_ptr<MessageForwardInfo> get_message_forward_info(
tl_object_ptr<telegram_api::messageFwdHeader> &&forward_header);