schmittjoh / serializer

Library for (de-)serializing data of any complexity (supports JSON, and XML)
http://jmsyst.com/libs/serializer
MIT License
2.32k stars 589 forks source link

Improve null checks in drivers with a delegate #1495

Closed mbabker closed 1 year ago

mbabker commented 1 year ago
Q A
Bug fix? yes
New feature? no
Doc updated no
BC breaks? no
Deprecations? no
Tests pass? yes
Fixed tickets N/A
License MIT

Split off from #1494

The metadata drivers with delegates inconsistently check for null responses, either the check is made after an assert() or it's not made at all. So this PR ensures we have these null checks and early returns before asserting the metadata object is a specific subclass.

scyzoryck commented 1 year ago

Thanks for contribution!