Skip to content

Conversation

@aurelschwitter
Copy link

Due to the nature that "[]" evaluates to $null when passed into ConvertFrom-Json, Compare-Object throws an error that the ReferenceObject cannot be null.

This change first compares the deployedObject and payloadObject if both are non-null and only then passes the two object to Compare-Object.
If one of the objects is null and the other is not, it will still throw an error, but the script will still stop the triggers as before which is good in this case (null != non-null).

For more details, see #540

@aurelschwitter aurelschwitter force-pushed the fix/540-trigger-payload-empty-array-issue branch from 87cd66b to cd9d4c9 Compare February 23, 2023 16:04
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant