File tree Expand file tree Collapse file tree 2 files changed +5
-5
lines changed
Modules/CIPPCore/Public/Entrypoints/HTTP Functions/CIPP/Settings Expand file tree Collapse file tree 2 files changed +5
-5
lines changed Original file line number Diff line number Diff line change @@ -25,7 +25,7 @@ Function Invoke-ExecAccessChecks {
2525 if ($Request.Query.SkipCache -ne ' true' -or $Request.Query.SkipCache -ne $true ) {
2626 try {
2727 $Cache = Get-CIPPAzDataTableEntity @Table - Filter " RowKey eq 'AccessPermissions' and Timestamp and Timestamp ge datetime'$TimestampFilter '"
28- $Results = $Cache.Data | ConvertFrom-Json
28+ $Results = $Cache.Data | ConvertFrom-Json - ErrorAction Stop
2929 } catch {
3030 $Results = $null
3131 }
@@ -62,7 +62,7 @@ Function Invoke-ExecAccessChecks {
6262 ExchangeTest = ' '
6363 }
6464 if ($TenantCheck ) {
65- $Data = @ ($TenantCheck.Data | ConvertFrom-Json )
65+ $Data = @ ($TenantCheck.Data | ConvertFrom-Json - ErrorAction Stop )
6666 $TenantResult.GraphStatus = $Data.GraphStatus
6767 $TenantResult.ExchangeStatus = $Data.ExchangeStatus
6868 $TenantResult.GDAPRoles = $Data.GDAPRoles
@@ -85,7 +85,7 @@ Function Invoke-ExecAccessChecks {
8585 $Results = @ ()
8686 }
8787 } catch {
88- Write-Host $ _.Exception.Message
88+ Write-Warning " Error running tenant access check - $ ( $ _.Exception.Message ) "
8989 $Results = @ ()
9090 }
9191 }
@@ -105,7 +105,7 @@ Function Invoke-ExecAccessChecks {
105105 if (! $Request.Query.SkipCache -eq ' true' -or ! $Request.Query.SkipCache -eq $true ) {
106106 try {
107107 $Cache = Get-CIPPAzDataTableEntity @Table - Filter " RowKey eq 'GDAPRelationships' and Timestamp ge datetime'$TimestampFilter '"
108- $Results = $Cache.Data | ConvertFrom-Json
108+ $Results = $Cache.Data | ConvertFrom-Json - ErrorAction Stop
109109 } catch {
110110 $Results = $null
111111 }
Original file line number Diff line number Diff line change 1- 7.5.0
1+ 7.5.1
You can’t perform that action at this time.
0 commit comments