Skip to content

Commit

Permalink
issue 585
Browse files Browse the repository at this point in the history
  • Loading branch information
gregslack78 committed Apr 23, 2024
1 parent 7092b09 commit 74c8254
Showing 1 changed file with 1 addition and 2 deletions.
3 changes: 1 addition & 2 deletions Scripts/Helpers/Get-AzPolicyAssignments.ps1
Original file line number Diff line number Diff line change
Expand Up @@ -47,8 +47,7 @@ function Get-AzPolicyAssignments {
$principalId = $policyResource.identity.principalId
}
else {
$userAssignedIdentityId = $policyResource.identity.userAssignedIdentities.PSObject.Properties.Name
$principalId = $policyResource.identity.userAssignedIdentities.$userAssignedIdentityId.principalId
$principalId = $policyResource.identity.userAssignedIdentities.Values.principalId
}
$uniquePrincipalIds[$principalId] = $true
$policyResourcesTable.counters.withIdentity += 1
Expand Down

0 comments on commit 74c8254

Please sign in to comment.