dedupe replies

This commit is contained in:
Henry Hiles 2025-11-12 14:33:37 -05:00
commit 1d03b09775
No known key found for this signature in database
7 changed files with 86 additions and 41 deletions

View file

@ -43,9 +43,11 @@ class RoomChatController extends AsyncNotifier<ChatController> {
return controller.updateMessage(message, newMessage);
}
Future<void> send(String message) async {
await room.sendTextEvent(message);
}
Future<void> send(String message, {String? replyTo}) async =>
await room.sendTextEvent(
message,
inReplyTo: replyTo == null ? null : await room.getEventById(replyTo),
);
Future<chat.User> resolveUser(String id) async {
final user = await room.client.getUserProfile(id);