mirror of
https://github.com/revoltchat/revite.git
synced 2024-11-25 08:30:58 -05:00
fix: don't cast message.content
This commit is contained in:
parent
ce5dedcecf
commit
7ffa0744c0
2 changed files with 8 additions and 6 deletions
|
@ -223,9 +223,10 @@ export const MessageReply = observer(
|
|||
)}
|
||||
<Markdown
|
||||
disallowBigEmoji
|
||||
content={(
|
||||
message.content as string
|
||||
).replace(/\n/g, " ")}
|
||||
content={message.content?.replace(
|
||||
/\n/g,
|
||||
" ",
|
||||
)}
|
||||
/>
|
||||
</div>
|
||||
</>
|
||||
|
|
|
@ -187,9 +187,10 @@ export default observer(({ channel, replies, setReplies }: Props) => {
|
|||
) : (
|
||||
<Markdown
|
||||
disallowBigEmoji
|
||||
content={(
|
||||
message.content as string
|
||||
).replace(/\n/g, " ")}
|
||||
content={message.content?.replace(
|
||||
/\n/g,
|
||||
" ",
|
||||
)}
|
||||
/>
|
||||
)}
|
||||
</div>
|
||||
|
|
Loading…
Reference in a new issue