Skip to content

Commit

Permalink
handle absence of dev script in upgrade codemod
Browse files Browse the repository at this point in the history
  • Loading branch information
imprakharshukla committed Oct 22, 2024
1 parent 236e001 commit 4375f7b
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion packages/next-codemod/bin/upgrade.ts
Original file line number Diff line number Diff line change
Expand Up @@ -410,7 +410,7 @@ function isUsingAppDir(projectPath: string): boolean {
*/
async function suggestTurbopack(packageJson: any): Promise<void> {
const devScript: string = packageJson.scripts['dev']
if (devScript.includes('--turbo')) return
if (devScript && devScript.includes('--turbo')) return

const responseTurbopack = await prompts(
{
Expand Down

0 comments on commit 4375f7b

Please sign in to comment.