Skip to content
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.

Commit 8e8ff06

Browse files
authoredApr 2, 2025··
FE: Messages: Format JSON arrays (#994)
Signed-off-by: Yarden Shoham <git@yardenshoham.com>
1 parent 1d40109 commit 8e8ff06

File tree

1 file changed

+3
-1
lines changed

1 file changed

+3
-1
lines changed
 

‎frontend/src/components/Topics/Topic/Messages/MessageContent/MessageContent.tsx

Lines changed: 3 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -59,7 +59,9 @@ const MessageContent: React.FC<MessageContentProps> = ({
5959
};
6060

6161
const contentType =
62-
messageContent && messageContent.trim().startsWith('{')
62+
messageContent &&
63+
(messageContent.trim().startsWith('{') ||
64+
messageContent.trim().startsWith('['))
6365
? SchemaType.JSON
6466
: SchemaType.PROTOBUF;
6567

0 commit comments

Comments
 (0)
Please sign in to comment.