Skip to content

Commit

Permalink
timeline view validation
Browse files Browse the repository at this point in the history
  • Loading branch information
ritch committed Oct 23, 2024
1 parent e0e0dc5 commit 37c8071
Showing 1 changed file with 6 additions and 7 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -20,13 +20,12 @@ export default function TimelineView(props: ViewPropsType) {
...providedcConfig,
};

const requiredParams = ["timeline_name", "total_frames"];

// for (const param of requiredParams) {
// if (!finalConfig[param]) {
// throw new Error(`Missing required parameter: ${param}`);
// }
// }
if (!timeline_name) {
throw new Error("Timeline name is required");
}
if (!finalConfig.totalFrames) {
throw new Error("Total frames is required");
}

return <TimelineCreator timelineName={timeline_name} {...finalConfig} />;
}
Expand Down

0 comments on commit 37c8071

Please sign in to comment.