Small fix for running using Invoke-Expression

A small fix suggested by a user for running ConfigureRemotingForAnsible.

This fixes #20512
pull/20666/head
Dag Wieers 8 years ago committed by Matt Clay
parent 899e336b1e
commit e64ef8b0ab

@ -114,7 +114,7 @@ Trap
} }
$ErrorActionPreference = "Stop" $ErrorActionPreference = "Stop"
$EventSource = $MyInvocation.MyCommand.Name $EventSource = $MyInvocation.MyCommand.Name
If ($EventSource -eq $Null) If (-Not $EventSource)
{ {
$EventSource = "Powershell CLI" $EventSource = "Powershell CLI"
} }

Loading…
Cancel
Save