diff --git a/src/chocolatey.resources/helpers/functions/Start-ChocolateyProcessAsAdmin.ps1 b/src/chocolatey.resources/helpers/functions/Start-ChocolateyProcessAsAdmin.ps1 index 0b884fd0ad..5d3ef8fd45 100644 --- a/src/chocolatey.resources/helpers/functions/Start-ChocolateyProcessAsAdmin.ps1 +++ b/src/chocolatey.resources/helpers/functions/Start-ChocolateyProcessAsAdmin.ps1 @@ -70,8 +70,10 @@ Elevating Permissions and running [`"$exeToRun`" $wrappedStatements]. This may t } if (!([System.IO.File]::Exists($exeToRun)) -and $exeToRun -notmatch 'msiexec') { - Set-PowerShellExitCode 2 - throw "Could not find '$exeToRun'" + Write-Warning "May not be able to find '$exeToRun'. Please use full path for executables." + # until we have search paths enabled, let's just pass a warning + #Set-PowerShellExitCode 2 + #throw "Could not find '$exeToRun'" } # Redirecting output slows things down a bit.