File tree Expand file tree Collapse file tree 1 file changed +5
-6
lines changed
Expand file tree Collapse file tree 1 file changed +5
-6
lines changed Original file line number Diff line number Diff line change @@ -68,6 +68,7 @@ export class SSHRuntime implements Runtime {
6868 /**
6969 * Execute command over SSH with streaming I/O
7070 */
71+ // eslint-disable-next-line @typescript-eslint/require-await
7172 async exec ( command : string , options : ExecOptions ) : Promise < ExecStream > {
7273 const startTime = performance . now ( ) ;
7374
@@ -241,12 +242,10 @@ export class SSHRuntime implements Runtime {
241242 let execPromise : Promise < ExecStream > | null = null ;
242243
243244 const getExecStream = ( ) => {
244- if ( ! execPromise ) {
245- execPromise = this . exec ( writeCommand , {
246- cwd : this . config . workdir ,
247- timeout : 300 , // 5 minutes - reasonable for large files
248- } ) ;
249- }
245+ execPromise ??= this . exec ( writeCommand , {
246+ cwd : this . config . workdir ,
247+ timeout : 300 , // 5 minutes - reasonable for large files
248+ } ) ;
250249 return execPromise ;
251250 } ;
252251
You can’t perform that action at this time.
0 commit comments