Skip to content

Commit

Permalink
Added anchor to EXO Cmdlet
Browse files Browse the repository at this point in the history
  • Loading branch information
Jr7468 committed Jun 18, 2024
1 parent 79a21a9 commit 693c3ac
Showing 1 changed file with 2 additions and 2 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -17,9 +17,9 @@ Function Invoke-ListCalendarPermissions {

try {
$GetCalParam = @{Identity = $UserID; FolderScope = 'Calendar' }
$CalendarFolder = New-ExoRequest -tenantid $Tenantfilter -cmdlet 'Get-MailboxFolderStatistics' -cmdParams $GetCalParam | Select-Object -First 1
$CalendarFolder = New-ExoRequest -tenantid $Tenantfilter -cmdlet 'Get-MailboxFolderStatistics' -anchor $UserID -cmdParams $GetCalParam | Select-Object -First 1
$CalParam = @{Identity = "$($UserID):\$($CalendarFolder.name)" }
$GraphRequest = New-ExoRequest -tenantid $Tenantfilter -cmdlet 'Get-MailboxFolderPermission' -cmdParams $CalParam -UseSystemMailbox $true | Select-Object Identity, User, AccessRights, FolderName
$GraphRequest = New-ExoRequest -tenantid $Tenantfilter -cmdlet 'Get-MailboxFolderPermission' -anchor $UserID -cmdParams $CalParam -UseSystemMailbox $true | Select-Object Identity, User, AccessRights, FolderName
Write-LogMessage -API 'List Calendar Permissions' -tenant $tenantfilter -message "Calendar permissions listed for $($tenantfilter)" -sev Debug
$StatusCode = [HttpStatusCode]::OK
} catch {
Expand Down

0 comments on commit 693c3ac

Please sign in to comment.