Fix regex bug

This commit is contained in:
Henry Hiles 2025-12-24 16:53:13 -05:00
commit 11a946e6ea
Signed by: Henry-Hiles
SSH key fingerprint: SHA256:VKQUdS31Q90KvX7EkKMHMBpUspcmItAh86a+v7PGiIs
4 changed files with 98 additions and 128 deletions

View file

@ -8,9 +8,7 @@ extension EventToMessage on Event {
bool mustBeText = false,
bool includeEdits = false,
}) async {
final replyId = relationshipType == RelationshipTypes.reply
? relationshipEventId
: null;
final replyId = inReplyToEventId();
final newEvent = (unsigned?["m.relations"] as Map?)?["m.replace"];
final event = newEvent == null ? this : Event.fromJson(newEvent, room);