src/UnitOfWork.php
public function getDirtyData(
        array $newSerializedModel,
        array $oldSerializedModel,
        ClassMetadata $classMetadata
    ): array {
        return $this->getDirtyFields(
            $newSerializedModel,
            $oldSerializedModel,
            $classMetadata
        );
    }
public function getDirtyData(
        array $newSerializedModel,
        array $oldSerializedModel,
        ClassMetadata $classMetadata
    ): array {
        return $this->getDirtyFields(
            $newSerializedModel,
            $oldSerializedModel,
            $classMetadata
        );
    }
return the new serialized model with only needed fields to update