File tree Expand file tree Collapse file tree 1 file changed +6
-1
lines changed
Expand file tree Collapse file tree 1 file changed +6
-1
lines changed Original file line number Diff line number Diff line change @@ -45,14 +45,19 @@ class LiveSyncService implements ILiveSyncService {
4545 public liveSync ( platform : string ) : IFuture < void > {
4646 return ( ( ) => {
4747 let liveSyncData : ILiveSyncData [ ] = [ ] ;
48- this . $devicesService . initialize ( { skipInferPlatform : true } ) . wait ( ) ;
4948 if ( platform ) {
49+ this . $devicesService . initialize ( { platform : platform , deviceId : this . $options . device } ) . wait ( ) ;
5050 liveSyncData . push ( this . prepareLiveSyncData ( platform ) ) ;
5151 } else if ( this . $options . device ) {
52+ this . $devicesService . initialize ( { platform : platform , deviceId : this . $options . device } ) . wait ( ) ;
5253 platform = this . $devicesService . getDeviceByIdentifier ( this . $options . device ) . deviceInfo . platform ;
5354 liveSyncData . push ( this . prepareLiveSyncData ( platform ) ) ;
5455 } else {
56+ this . $devicesService . initialize ( { skipInferPlatform : true } ) . wait ( ) ;
5557 for ( let installedPlatform of this . $platformService . getInstalledPlatforms ( ) . wait ( ) ) {
58+ if ( this . $devicesService . getDevicesForPlatform ( installedPlatform ) . length === 0 ) {
59+ this . $devicesService . startEmulator ( installedPlatform ) . wait ( ) ;
60+ }
5661 liveSyncData . push ( this . prepareLiveSyncData ( installedPlatform ) ) ;
5762 }
5863 }
You can’t perform that action at this time.
0 commit comments