From 98ca8a7169220e35bc1e89da2e38dbdc2f60a90c Mon Sep 17 00:00:00 2001 From: Martin Vladic Date: Mon, 21 Oct 2024 17:47:52 +0200 Subject: [PATCH] fixed search crash --- packages/project-editor/ui-components/Output.tsx | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/packages/project-editor/ui-components/Output.tsx b/packages/project-editor/ui-components/Output.tsx index 065a631e..bf165197 100644 --- a/packages/project-editor/ui-components/Output.tsx +++ b/packages/project-editor/ui-components/Output.tsx @@ -203,8 +203,8 @@ const MessageContent = observer( let text = typeof this.props.message.text == "string" - ? this.props.message.text.toString() - : this.props.message.text; + ? this.props.message.text + : this.props.message.text?.toString() ?? ""; if (text.length > MAX_OUTPUT_MESSAGE_TEXT_SIZE) { text = text.substring(0, MAX_OUTPUT_MESSAGE_TEXT_SIZE) + "..."; }