Skip to content
This repository has been archived by the owner on Sep 8, 2024. It is now read-only.

Commit

Permalink
fix: unperfect consideration of json importing
Browse files Browse the repository at this point in the history
  • Loading branch information
sheepbox8646 committed Aug 12, 2024
1 parent 166dc86 commit 0a73b58
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion packages/json/src/import-widget.ts
Original file line number Diff line number Diff line change
Expand Up @@ -75,7 +75,7 @@ export function importWidget<T extends typeof Widget>(
if (typeof widgetData === 'string') {
widgetData = JSON.parse(widgetData) as WidgetFormat
}
const widget = new widgets[widgetData.type](...processArguments(widgetData.arguments), processOptions(widgetData.options))
const widget = new widgets[widgetData.type](...processArguments(widgetData.arguments ?? []), processOptions(widgetData.options))
if (widgetData.children) {
widget.add(...widgetData.children.map((child) => {
return importWidget(child, widgets, anims, easingFunctions)
Expand Down

0 comments on commit 0a73b58

Please sign in to comment.