Skip to content

Commit

Permalink
fix: always display the "no main/default" warning even in dry-run
Browse files Browse the repository at this point in the history
  • Loading branch information
mshanemc committed Aug 16, 2024
1 parent 13462f0 commit e122e72
Showing 1 changed file with 4 additions and 3 deletions.
7 changes: 4 additions & 3 deletions src/commands/project/convert/source-behavior.ts
Original file line number Diff line number Diff line change
Expand Up @@ -65,11 +65,12 @@ export default class ConvertSourceBehavior extends SfCommand<SourceBehaviorResul
getPackageDirectoriesForPreset(this.project!, flags.behavior),
]);

if (!packageDirsWithDecomposable.every(hasMainDefault(this.project!.getPath()))) {
this.warn(messages.getMessage('mainDefaultConfirmation'));
}

if (!flags['dry-run']) {
this.warn(messages.getMessage('basicConfirmation'));
if (!packageDirsWithDecomposable.every(hasMainDefault(this.project!.getPath()))) {
this.warn(messages.getMessage('mainDefaultConfirmation'));
}
await this.confirm({ message: 'Proceed' });
}
const filesToDelete = await convertToMdapi(packageDirsWithDecomposable);
Expand Down

0 comments on commit e122e72

Please sign in to comment.