From 5ff5e4f9f020d5ca462b0d5de3d952be79ca8052 Mon Sep 17 00:00:00 2001 From: Cory Miller <13227161+cory-miller@users.noreply.github.com> Date: Fri, 17 Feb 2023 21:19:50 +0000 Subject: [PATCH] . --- packages/io/src/io.ts | 8 ++++---- 1 file changed, 4 insertions(+), 4 deletions(-) diff --git a/packages/io/src/io.ts b/packages/io/src/io.ts index 1ce723fe..1585d5ad 100644 --- a/packages/io/src/io.ts +++ b/packages/io/src/io.ts @@ -134,7 +134,7 @@ export async function rmRF(inputPath: string): Promise { resolve('timeout') }, 500) - let result = null + let result: childProcess.ChildProcess if (await ioUtil.isDirectory(inputPath, true)) { result = childProcess.spawn( cmdPath, @@ -153,15 +153,15 @@ export async function rmRF(inputPath: string): Promise { ) } - result.on('spawn', (data) => { + result.on('spawn', () => { console.log(`spawn: ${result.spawnargs}`) }) - result.stdout.on('data', (data) => { + result.stdout?.on('data', (data) => { console.log(`stdout: ${data}`) }); - result.stderr.on('data', (data) => { + result.stderr?.on('data', (data) => { console.log(`stdout: ${data}`) });