Skip to content

Commit ec03dd2

Browse files
Merge branch 'dev' of https://github.com/KelvinTegelaar/CIPP-API into dev
2 parents 61f0943 + c017e15 commit ec03dd2

File tree

1 file changed

+1
-1
lines changed

1 file changed

+1
-1
lines changed

Modules/CIPPCore/Public/Authentication/Test-CIPPAccessUserRole.ps1

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -35,7 +35,7 @@ function Test-CIPPAccessUserRole {
3535
} else {
3636
try {
3737
$uri = "https://graph.microsoft.com/beta/users/$($User.userDetails)/transitiveMemberOf"
38-
$Memberships = New-GraphGetRequest -uri $uri -NoAuthCheck $true | Where-Object { $_.'@odata.type' -eq '#microsoft.graph.group' }
38+
$Memberships = New-GraphGetRequest -uri $uri -NoAuthCheck $true -AsApp $true | Where-Object { $_.'@odata.type' -eq '#microsoft.graph.group' }
3939
if ($Memberships) {
4040
Write-Information "Found group memberships for $($User.userDetails)"
4141
} else {

0 commit comments

Comments
 (0)