File tree Expand file tree Collapse file tree 1 file changed +9
-14
lines changed Expand file tree Collapse file tree 1 file changed +9
-14
lines changed Original file line number Diff line number Diff line change @@ -813,20 +813,15 @@ function startConnect() {
813813 terminal ( path , tasksComplete ) ;
814814 } ) ;
815815 } else {
816- //closure for stepping through each port
817- //and connect + upload (use timeout callback [iterate] for proceeding)
818- ( function ( ports , connect ) {
819- this . ports = ports ;
820- this . idx = 0 ;
821- this . connect = connect ;
822- this . iterate = function ( ) {
823- if ( this . idx >= ports . length ) tasksComplete ( ) ;
824- else getPortPath ( ports [ this . idx ++ ] , function ( path ) {
825- connect ( path , this . iterate ) ;
826- } ) ;
827- } ;
828- this . iterate ( ) ;
829- } ) ( args . ports , connect ) ;
816+ // stepping through each port and connect + upload
817+ let ports = args . ports , idx = 0 ;
818+ let iterate = function ( ) {
819+ if ( idx >= ports . length ) tasksComplete ( ) ;
820+ else getPortPath ( ports [ idx ++ ] , function ( path ) {
821+ connect ( path , iterate ) ;
822+ } ) ;
823+ } ;
824+ iterate ( ) ;
830825 }
831826}
832827
You can’t perform that action at this time.
0 commit comments