diff --git a/lib/shared/permissions.ts b/lib/shared/permissions.ts index 516eea13..3102851a 100755 --- a/lib/shared/permissions.ts +++ b/lib/shared/permissions.ts @@ -40,7 +40,7 @@ function sudoExecAsync( cmd, options, (error: Error | undefined, stdout: Std, stderr: Std) => { - if (error !== undefined) { + if (error) { reject(error); } else { resolve({ stdout, stderr });