Skip to content

Commit

Permalink
win_domain_group_membership - Fix to a fix in extra_args (ansible#58943)
Browse files Browse the repository at this point in the history
* win_domain_group_membership - Fix to a fix in extra_args

* addig missing l on the fly
  • Loading branch information
ShachafGoldstein authored and jborean93 committed Jul 16, 2019
1 parent e5e3486 commit 681ab65
Showing 1 changed file with 2 additions and 2 deletions.
4 changes: 2 additions & 2 deletions lib/ansible/modules/windows/win_domain_group_membership.ps1
Original file line number Diff line number Diff line change
Expand Up @@ -35,7 +35,7 @@ if ($null -ne $domain_username) {
$credential = New-Object -TypeName System.Management.Automation.PSCredential -ArgumentList $domain_username, $domain_password
$extra_args.Credential = $credential
}
if ($nul -ne $domain_server) {
if ($null -ne $domain_server) {
$extra_args.Server = $domain_server
}

Expand All @@ -52,7 +52,7 @@ $members_before = Get-AdGroupMember -Identity $name @extra_args
$pure_members = [System.Collections.Generic.List`1[String]]@()

foreach ($member in $members) {
$group_member = Get-ADObject -Filter "SamAccountName -eq '$member' -and $ad_object_class_filter" -Properties objectSid, sAMAccountName @extra_vars
$group_member = Get-ADObject -Filter "SamAccountName -eq '$member' -and $ad_object_class_filter" -Properties objectSid, sAMAccountName @extra_args
if (!$group_member) {
Fail-Json -obj $result "Could not find domain user, group, service account or computer named $member"
}
Expand Down

0 comments on commit 681ab65

Please sign in to comment.