Skip to content

Commit 0b72ea5

Browse files
committed
Update Compare-CIPPIntuneObject.ps1
1 parent d30b2f4 commit 0b72ea5

1 file changed

Lines changed: 4 additions & 3 deletions

File tree

Modules/CIPPCore/Public/Compare-CIPPIntuneObject.ps1

Lines changed: 4 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -173,11 +173,12 @@ function Compare-CIPPIntuneObject {
173173
if (ShouldCompareAsUnorderedSet -PropertyPath $PropertyPath) {
174174
# For unordered sets, compare contents regardless of order
175175
if ($Object1.Count -ne $Object2.Count) {
176-
# Different lengths - report the difference
176+
# Different lengths - report the actual values so a technician
177+
# can see exactly what differs and decide on the action.
177178
$result.Add([PSCustomObject]@{
178179
Property = $PropertyPath
179-
ExpectedValue = "Array with $($Object1.Count) items"
180-
ReceivedValue = "Array with $($Object2.Count) items"
180+
ExpectedValue = ($Object1 -join ', ')
181+
ReceivedValue = ($Object2 -join ', ')
181182
})
182183
} else {
183184
# Same length - check if all items exist in both arrays

0 commit comments

Comments
 (0)