Skip to content

Commit 5cfb440

Browse files
committed
fix(contextchat): sources are json string in a list
Signed-off-by: Anupam Kumar <kyteinsky@gmail.com>
1 parent ba827da commit 5cfb440

File tree

1 file changed

+1
-1
lines changed

1 file changed

+1
-1
lines changed

src/components/ContextChat/ContextChatOutputForm.vue

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -76,7 +76,7 @@ export default {
7676
computed: {
7777
sources() {
7878
try {
79-
return JSON.parse(this.output.sources)
79+
return this.output?.sources?.map(JSON.parse) ?? []
8080
} catch (e) {
8181
console.error('Failed to parse sources', e)
8282
return []

0 commit comments

Comments
 (0)