Skip to content
This repository was archived by the owner on Mar 26, 2026. It is now read-only.

Commit 637d7f7

Browse files
vitbokischclaude
andcommitted
Fix typecheck: handle undefined in validate callback
Co-Authored-By: Claude Opus 4.6 (1M context) <noreply@anthropic.com>
1 parent 9a675c0 commit 637d7f7

1 file changed

Lines changed: 1 addition & 1 deletion

File tree

packages/create-zero/src/index.ts

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -94,7 +94,7 @@ async function main() {
9494
message: 'Project name',
9595
placeholder: 'my-zero-app',
9696
validate: (v) => {
97-
if (!v.trim()) return 'Project name is required'
97+
if (!v?.trim()) return 'Project name is required'
9898
if (existsSync(resolve(process.cwd(), v))) return `Directory "${v}" already exists`
9999
},
100100
}))

0 commit comments

Comments
 (0)