fix(content): guard optional durationMs and cover loop validation

This commit is contained in:
ginnoir
2026-06-11 20:17:50 -05:00
parent c48e53cc7b
commit c1b38e36aa
4 changed files with 20 additions and 2 deletions
+1 -1
View File
@@ -61,7 +61,7 @@ export const actionDefSchema = z
path: ['durationMs'],
});
}
if (action.kind === 'story' && !action.storyChoiceId) {
if (action.kind === 'story' && action.storyChoiceId === undefined) {
ctx.addIssue({
code: 'custom',
message: 'story actions require storyChoiceId',