From a7df9a735d0a2272ba8ff9840aa5b4d3b5ad86db Mon Sep 17 00:00:00 2001 From: Krille Date: Fri, 27 Dec 2024 14:06:26 +0100 Subject: [PATCH] refactor: Add already available file metadata to placeholder event when sending a file --- lib/src/room.dart | 5 +++++ 1 file changed, 5 insertions(+) diff --git a/lib/src/room.dart b/lib/src/room.dart index 255fdd62..b607a5cd 100644 --- a/lib/src/room.dart +++ b/lib/src/room.dart @@ -734,6 +734,11 @@ class Room { 'msgtype': file.msgType, 'body': file.name, 'filename': file.name, + 'info': { + ...file.info, + if (thumbnail != null) 'thumbnail_info': thumbnail.info, + }, + if (extraContent != null) ...extraContent, }, type: EventTypes.Message, eventId: txid,