fix: error handling for 6.1.2/6.1.3
This commit is contained in:
@@ -43,7 +43,7 @@ function Test-MailboxAuditingE3 {
|
|||||||
|
|
||||||
|
|
||||||
process {
|
process {
|
||||||
if ($null -ne $founde3Sku) {
|
if (($founde3Sku.count)-ne 0) {
|
||||||
$allUsers = Get-MgUser -Filter "assignedLicenses/any(x:x/skuId eq $($founde3Sku.SkuId) )" -All
|
$allUsers = Get-MgUser -Filter "assignedLicenses/any(x:x/skuId eq $($founde3Sku.SkuId) )" -All
|
||||||
$mailboxes = Get-EXOMailbox -PropertySets Audit
|
$mailboxes = Get-EXOMailbox -PropertySets Audit
|
||||||
try {
|
try {
|
||||||
|
@@ -40,7 +40,7 @@ function Test-MailboxAuditingE5 {
|
|||||||
}
|
}
|
||||||
|
|
||||||
process {
|
process {
|
||||||
if ($null -ne $founde5Sku) {
|
if (($founde5Sku.count) -ne 0) {
|
||||||
$allUsers = Get-MgUser -Filter "assignedLicenses/any(x:x/skuId eq $($founde5Sku.SkuId) )" -All
|
$allUsers = Get-MgUser -Filter "assignedLicenses/any(x:x/skuId eq $($founde5Sku.SkuId) )" -All
|
||||||
$mailboxes = Get-EXOMailbox -PropertySets Audit
|
$mailboxes = Get-EXOMailbox -PropertySets Audit
|
||||||
try {
|
try {
|
||||||
|
Reference in New Issue
Block a user