chore: check the legacy incompatible message type (#3248)
This commit is contained in:
parent
f0f23078f3
commit
c10caf8d7f
@ -61,6 +61,8 @@ const SimpleTextMessage: React.FC<Props> = ({
|
|||||||
const message = msg.content[0]
|
const message = msg.content[0]
|
||||||
if (message && message.type === 'text') {
|
if (message && message.type === 'text') {
|
||||||
const textBlockContent = message as TextContentBlock
|
const textBlockContent = message as TextContentBlock
|
||||||
|
// Check for compatible message object type - There was a problem with legacy message object compatibility, which broke the app.
|
||||||
|
if (typeof textBlockContent.text.value === 'string')
|
||||||
setText(textBlockContent.text.value)
|
setText(textBlockContent.text.value)
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|||||||
Loading…
x
Reference in New Issue
Block a user