Check message content type in on_get_recent_locations.
GitOrigin-RevId: 50f343e2f8a6e023b50d57663a4b7f27e6f4088c
This commit is contained in:
parent
23cd9f656f
commit
c9a9e386e5
@ -7216,6 +7216,12 @@ void MessagesManager::on_get_recent_locations(DialogId dialog_id, int32 limit, i
|
||||
LOG(ERROR) << "Receive " << new_message << " instead of a message in " << dialog_id;
|
||||
continue;
|
||||
}
|
||||
auto m = get_message(new_message);
|
||||
if (m->content->get_id() != MessageLiveLocation::ID) {
|
||||
LOG(ERROR) << "Receive a message of wrong type " << m->content->get_id() << " in on_get_recent_locations in "
|
||||
<< dialog_id;
|
||||
continue;
|
||||
}
|
||||
|
||||
result.push_back(new_message.get_message_id());
|
||||
} else {
|
||||
|
Reference in New Issue
Block a user