fixes
This commit is contained in:
@@ -429,10 +429,17 @@ impl TdClient {
|
||||
|
||||
match existing_idx {
|
||||
Some(idx) => {
|
||||
// Сообщение уже есть - обновляем только если входящее
|
||||
// (исходящие уже добавлены через send_message с правильным reply_to)
|
||||
// Сообщение уже есть - обновляем
|
||||
if is_incoming {
|
||||
self.current_chat_messages[idx] = msg_info;
|
||||
} else {
|
||||
// Для исходящих: обновляем can_be_edited и другие поля,
|
||||
// но сохраняем reply_to (добавленный при отправке)
|
||||
let existing = &mut self.current_chat_messages[idx];
|
||||
existing.can_be_edited = msg_info.can_be_edited;
|
||||
existing.can_be_deleted_only_for_self = msg_info.can_be_deleted_only_for_self;
|
||||
existing.can_be_deleted_for_all_users = msg_info.can_be_deleted_for_all_users;
|
||||
existing.is_read = msg_info.is_read;
|
||||
}
|
||||
}
|
||||
None => {
|
||||
|
||||
Reference in New Issue
Block a user