diff --git a/src/components/views/rooms/SendMessageComposer.tsx b/src/components/views/rooms/SendMessageComposer.tsx index cda78c36b0..ba8f99f47f 100644 --- a/src/components/views/rooms/SendMessageComposer.tsx +++ b/src/components/views/rooms/SendMessageComposer.tsx @@ -64,7 +64,6 @@ function addReplyToMessageContent( content: IContent, replyToEvent: MatrixEvent, permalinkCreator: RoomPermalinkCreator, - relation?: IEventRelation, ): void { const replyContent = ReplyChain.makeReplyMixIn(replyToEvent); Object.assign(content, replyContent); @@ -78,7 +77,12 @@ function addReplyToMessageContent( } content.body = nestedReply.body + content.body; } +} +export function attachRelation( + content: IContent, + relation?: IEventRelation, +): void { if (relation) { content['m.relates_to'] = { ...relation, // the composer can have a default @@ -417,9 +421,9 @@ export class SendMessageComposer extends React.Component