mirror of
https://github.com/danog/telegram-tt.git
synced 2024-11-30 04:39:00 +01:00
Service Notifications: Fix loading media
This commit is contained in:
parent
9f7f01b0bd
commit
14b603991f
@ -632,6 +632,7 @@ addActionHandler('createServiceNotification', (global, actions, payload) => {
|
||||
// The fractional ID is made of the largest integer ID and an incremented fractional part
|
||||
const id = Math.floor(maxId) + fractionalPart;
|
||||
|
||||
message.previousLocalId = message.id;
|
||||
message.id = id;
|
||||
|
||||
const serviceNotification = {
|
||||
|
@ -23,9 +23,9 @@ export function getMessageHtmlId(messageId: number) {
|
||||
}
|
||||
|
||||
export function getMessageKey(message: ApiMessage): MessageKey {
|
||||
const { chatId, id } = message;
|
||||
const { chatId, id, previousLocalId } = message;
|
||||
|
||||
return buildMessageKey(chatId, id);
|
||||
return buildMessageKey(chatId, isServiceNotificationMessage(message) ? previousLocalId || id : id);
|
||||
}
|
||||
|
||||
export function buildMessageKey(chatId: string, msgId: number): MessageKey {
|
||||
|
Loading…
Reference in New Issue
Block a user