@@ -11,8 +11,8 @@ export abstract class BuildCommandBase extends ValidatePlatformCommandBase {
1111 $platformValidationService : IPlatformValidationService ,
1212 private $buildDataService : IBuildDataService ,
1313 protected $logger : ILogger ) {
14- super ( $options , $platformsDataService , $platformValidationService , $projectData ) ;
15- this . $projectData . initializeProjectData ( ) ;
14+ super ( $options , $platformsDataService , $platformValidationService , $projectData ) ;
15+ this . $projectData . initializeProjectData ( ) ;
1616 }
1717
1818 public dashedOptions = {
@@ -65,16 +65,16 @@ export class BuildIosCommand extends BuildCommandBase implements ICommand {
6565 $logger : ILogger ,
6666 $buildDataService : IBuildDataService ,
6767 private $migrateController : IMigrateController ) {
68- super ( $options , $errors , $projectData , $platformsDataService , $devicePlatformsConstants , $buildController , $platformValidationService , $buildDataService , $logger ) ;
68+ super ( $options , $errors , $projectData , $platformsDataService , $devicePlatformsConstants , $buildController , $platformValidationService , $buildDataService , $logger ) ;
6969 }
7070
7171 public async execute ( args : string [ ] ) : Promise < void > {
7272 await this . executeCore ( [ this . $devicePlatformsConstants . iOS . toLowerCase ( ) ] ) ;
7373 }
7474
7575 public async canExecute ( args : string [ ] ) : Promise < boolean | ICanExecuteCommandOutput > {
76- await this . $migrateController . validate ( { projectDir : this . $projectData . projectDir } ) ;
7776 const platform = this . $devicePlatformsConstants . iOS ;
77+ await this . $migrateController . validate ( { projectDir : this . $projectData . projectDir , platforms : [ platform ] } ) ;
7878
7979 super . validatePlatform ( platform ) ;
8080
@@ -103,7 +103,7 @@ export class BuildAndroidCommand extends BuildCommandBase implements ICommand {
103103 $buildDataService : IBuildDataService ,
104104 protected $logger : ILogger ,
105105 private $migrateController : IMigrateController ) {
106- super ( $options , $errors , $projectData , platformsDataService , $devicePlatformsConstants , $buildController , $platformValidationService , $buildDataService , $logger ) ;
106+ super ( $options , $errors , $projectData , platformsDataService , $devicePlatformsConstants , $buildController , $platformValidationService , $buildDataService , $logger ) ;
107107 }
108108
109109 public async execute ( args : string [ ] ) : Promise < void > {
@@ -119,8 +119,8 @@ export class BuildAndroidCommand extends BuildCommandBase implements ICommand {
119119 }
120120
121121 public async canExecute ( args : string [ ] ) : Promise < boolean | ICanExecuteCommandOutput > {
122- await this . $migrateController . validate ( { projectDir : this . $projectData . projectDir } ) ;
123122 const platform = this . $devicePlatformsConstants . Android ;
123+ await this . $migrateController . validate ( { projectDir : this . $projectData . projectDir , platforms : [ platform ] } ) ;
124124 this . $androidBundleValidatorHelper . validateRuntimeVersion ( this . $projectData ) ;
125125 let result = await super . canExecuteCommandBase ( platform , { notConfiguredEnvOptions : { hideSyncToPreviewAppOption : true } } ) ;
126126 if ( result . canExecute ) {
0 commit comments