Remove the warning that the installation check command was not found

This commit is contained in:
Howard Wu 2023-03-26 03:02:05 +08:00 committed by GitHub
parent 58e17da60a
commit c889b66e93
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23

View File

@ -41,7 +41,7 @@ Function Test-CommandExists {
$oldPreference = $ErrorActionPreference
$ErrorActionPreference = 'stop'
try { if (Get-Command $command) { RETURN $true } }
Catch { Write-Host "$command does not exist"; RETURN $false }
Catch { RETURN $false }
Finally { $ErrorActionPreference = $oldPreference }
} #end function test-CommandExists