This repository was archived by the owner on Jan 21, 2021. It is now read-only.
File tree Expand file tree Collapse file tree 1 file changed +7
-7
lines changed Expand file tree Collapse file tree 1 file changed +7
-7
lines changed Original file line number Diff line number Diff line change @@ -6141,13 +6141,13 @@ filter Get-GroupsXML {
61416141 [XML ]$GroupsXMLcontent = Get-Content $TargetGroupsXMLPath - ErrorAction Stop
61426142
61436143 # process all group properties in the XML
6144- $GroupsXMLcontent | Select-Xml " // Groups" | Select-Object - ExpandProperty node | ForEach-Object {
6144+ $GroupsXMLcontent | Select-Xml " /Groups/Group " | Select-Object - ExpandProperty node | ForEach-Object {
61456145
6146- $Groupname = $_.Group. Properties.groupName
6146+ $Groupname = $_.Properties.groupName
61476147
61486148 # extract the localgroup sid for memberof
6149- $GroupSID = $_.Group. Properties.GroupSid
6150- if (-not $LocalSid ) {
6149+ $GroupSID = $_.Properties.groupSid
6150+ if (-not $GroupSID ) {
61516151 if ($Groupname -match ' Administrators' ) {
61526152 $GroupSID = ' S-1-5-32-544'
61536153 }
@@ -6163,16 +6163,16 @@ filter Get-GroupsXML {
61636163 }
61646164
61656165 # extract out members added to this group
6166- $Members = $_.Group. Properties.members | Select-Object - ExpandProperty Member | Where-Object { $_.action -match ' ADD' } | ForEach-Object {
6166+ $Members = $_.Properties.members | Select-Object - ExpandProperty Member | Where-Object { $_.action -match ' ADD' } | ForEach-Object {
61676167 if ($_.sid ) { $_.sid }
61686168 else { $_.name }
61696169 }
61706170
61716171 if ($Members ) {
61726172
61736173 # extract out any/all filters...I hate you GPP
6174- if ($_.Group. filters ) {
6175- $Filters = $_.Group. filters.GetEnumerator () | ForEach-Object {
6174+ if ($_.filters ) {
6175+ $Filters = $_.filters.GetEnumerator () | ForEach-Object {
61766176 New-Object - TypeName PSObject - Property @ {' Type' = $_.LocalName ;' Value' = $_.name }
61776177 }
61786178 }
You can’t perform that action at this time.
0 commit comments