Skip to content

Commit

Permalink
Fix wasm entity creation with array type fields
Browse files Browse the repository at this point in the history
  • Loading branch information
prathamesh0 committed Nov 17, 2023
1 parent 7eb02dc commit 4f1271b
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion packages/util/src/graph/utils.ts
Original file line number Diff line number Diff line change
Expand Up @@ -643,7 +643,7 @@ export const formatEntityValue = async (instanceExports: any, type: string, valu
let typeName = type;
if (isArray) {
typeName = 'Array';
valueToFormat = value.map((el: any) => { return { type, data: el }; });
valueToFormat = value.map((el: any) => { return { type: TypeNameToValueKind[type] ?? ValueKind.STRING, data: el }; });
}

return formatValue(instanceExports, TypeNameToValueKind[typeName] ?? ValueKind.STRING, valueToFormat);
Expand Down

0 comments on commit 4f1271b

Please sign in to comment.