Skip to content

Commit

Permalink
Drop is_outgoing only in the API message object.
Browse files Browse the repository at this point in the history
  • Loading branch information
levlam committed Oct 30, 2024
1 parent 29e984f commit 8b5d845
Showing 1 changed file with 3 additions and 3 deletions.
6 changes: 3 additions & 3 deletions td/telegram/MessagesManager.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -13643,9 +13643,6 @@ std::pair<DialogId, unique_ptr<MessagesManager::Message>> MessagesManager::creat
LOG(ERROR) << "Receive pinned " << message_id << " in " << dialog_id;
is_pinned = false;
}
if (message_info.is_from_scheduled && is_outgoing && is_bot) {
is_outgoing = false;
}

bool has_mention =
message_info.has_mention || (content_type == MessageContentType::PinMessage &&
Expand Down Expand Up @@ -23229,6 +23226,9 @@ td_api::object_ptr<td_api::message> MessagesManager::get_message_object(DialogId
is_scheduled || m->forward_info == nullptr ||
(!m->forward_info->get_last_dialog_id().is_valid() && !m->forward_info->get_origin().is_sender_hidden());
}
if (m->is_from_scheduled && is_outgoing && is_bot) {
is_outgoing = false;
}

double ttl_expires_in =
m->ttl_expires_at != 0 ? clamp(m->ttl_expires_at - Time::now(), 1e-3, m->ttl.get_input_ttl() - 1e-3) : 0.0;
Expand Down

0 comments on commit 8b5d845

Please sign in to comment.