-
Notifications
You must be signed in to change notification settings - Fork 24
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
group - fix setting explicitly empty members #144
Conversation
Build succeeded. ✔️ ansible-galaxy-importer SUCCESS in 4m 34s |
Add a fix when attempting to create a group with an explicitly empty set of members. This fix also applies to any other add/set/remove attribute when the resulting value is an empty value. The error only applied when creating the AD object as the `New-AD* -OtherAttributes` parameter could not handle an empty array value.
b2d60d0
to
650f0c0
Compare
Build succeeded. ✔️ ansible-galaxy-importer SUCCESS in 4m 37s |
plugins/module_utils/_ADObject.psm1
Outdated
@@ -1293,6 +1295,7 @@ Function Invoke-AnsibleADObject { | |||
$adObject = & $newCommand @newParams @adParams | |||
} | |||
catch { | |||
$module.Result.zzz = $newParams |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
zzz
? was this a debugging thing?
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
It was, thanks for picking it up.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
lgtm, thanks for the fix!
Build succeeded. ✔️ ansible-galaxy-importer SUCCESS in 3m 51s |
No worries, thanks for the bug report and reviewing. |
SUMMARY
Add a fix when attempting to create a group with an explicitly empty set of members. This fix also applies to any other add/set/remove attribute when the resulting value is an empty value. The error only applied when creating the AD object as the
New-AD* -OtherAttributes
parameter could not handle an empty array value.Fixes: #141
ISSUE TYPE
COMPONENT NAME
microsoft.ad.group (and others)