Skip to content

Commit 9cba4a1

Browse files
committed
refactor(cli): use ifDefined for conditional driver spread in migration show
Matches the existing convention used in migration-apply, migration-status, and contract-emit (per CodeRabbit nitpick).
1 parent ffed10c commit 9cba4a1

1 file changed

Lines changed: 2 additions & 1 deletion

File tree

packages/1-framework/3-tooling/cli/src/commands/migration-show.ts

Lines changed: 2 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -13,6 +13,7 @@ import {
1313
} from '@prisma-next/migration-tools/migration-graph';
1414
import type { OnDiskMigrationPackage } from '@prisma-next/migration-tools/package';
1515
import { spaceMigrationDirectory } from '@prisma-next/migration-tools/spaces';
16+
import { ifDefined } from '@prisma-next/utils/defined';
1617
import { notOk, ok, type Result } from '@prisma-next/utils/result';
1718
import { Command } from 'commander';
1819
import { relative, resolve } from 'pathe';
@@ -266,7 +267,7 @@ async function executeMigrationShowCommand(
266267
family: config.family,
267268
target: config.target,
268269
adapter: config.adapter,
269-
...(config.driver ? { driver: config.driver } : {}),
270+
...ifDefined('driver', config.driver),
270271
extensionPacks: config.extensionPacks ?? [],
271272
});
272273

0 commit comments

Comments
 (0)