1
0
Fork 0

code formatting

This commit is contained in:
Christian Kühnel 2019-12-16 09:47:02 +00:00
parent 7ab62f2aea
commit c3fd873495

View file

@ -43,7 +43,7 @@ function Invoke-Call {
[scriptblock]$ScriptBlock, [scriptblock]$ScriptBlock,
[string]$ErrorAction = $ErrorActionPreference [string]$ErrorAction = $ErrorActionPreference
) )
& @ScriptBlock 2>&1 3>&1 4>&1| ForEach-Object { "$_" } & @ScriptBlock 2>&1 3>&1 4>&1 | ForEach-Object { "$_" }
if (($lastexitcode -ne 0) -and $ErrorAction -eq "Stop") { if (($lastexitcode -ne 0) -and $ErrorAction -eq "Stop") {
Write-Error "Command $ScriptBlock exited with $lastexitcode." Write-Error "Command $ScriptBlock exited with $lastexitcode."
exit $lastexitcode exit $lastexitcode