You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
Write-LogMessage-API 'Standards'-tenant $Tenant-message "Outlook external spoof warnings are already set to $status."-sev Info
61
-
} else {
62
-
try {
78
+
try {
79
+
if ($CurrentInfo.Enabled-eq$status-and$AllowListCorrect-eq$true) {
80
+
# Status correct, AllowList correct
81
+
Write-LogMessage-API 'Standards'-tenant $Tenant-message "Outlook external spoof warnings are already set to $status and the AllowList is correct."-sev Info
Write-LogMessage-API 'Standards'-tenant $Tenant-message "Outlook external spoof warnings already set to $status. Added $($AllowListAdd.Add-join', ') to the AllowList."-sev Info
Write-LogMessage-API 'Standards'-tenant $Tenant-message "Outlook external spoof warnings set to $status. Added $($AllowListAdd.Add-join', ') to the AllowList."-sev Info
Write-LogMessage-API 'Standards'-tenant $Tenant-message "Outlook external spoof warnings set to $status."-sev Info
65
-
} catch {
66
-
$ErrorMessage=Get-CippException-Exception $_
67
-
Write-LogMessage-API 'Standards'-tenant $Tenant-message "Could not set Outlook external spoof warnings to $status. Error: $($ErrorMessage.NormalizedError)"-sev Error -LogData $ErrorMessage
97
+
68
98
}
99
+
} catch {
100
+
$ErrorMessage=Get-CippException-Exception $_
101
+
Write-LogMessage-API 'Standards'-tenant $Tenant-message "Could not set Outlook external spoof warnings to $status. Error: $($ErrorMessage.NormalizedError)"-sev Error -LogData $ErrorMessage
0 commit comments