Removes null fields from current object before matching because there are cases where it's necessary.
Why?
Persistentvolumeclaimtemplates in StatefulSets are root objects and for example the CreationTimestamp field will not be set in it, but left empty, which will be null. This will result in an unnecessary diff, that we want to avoid, thus removing null fields from current.
What's in this PR?
Removes null fields from current object before matching because there are cases where it's necessary.
Why?
Persistentvolumeclaimtemplates in StatefulSets are root objects and for example the CreationTimestamp field will not be set in it, but left empty, which will be null. This will result in an unnecessary diff, that we want to avoid, thus removing null fields from current.
Additional context
The issue came up in the bank-vaults project.