1
0
mirror of synced 2025-02-03 05:49:25 +03:00

Use yoda condition in the null check

This commit is contained in:
Carl Vuorinen 2016-09-04 18:37:03 +03:00 committed by Marco Pivetta
parent 95546d68c5
commit 00bbf4f523

View File

@ -122,7 +122,7 @@ class SimpleObjectHydrator extends AbstractHydrator
} }
// Check if value is null before conversion (because some types convert null to something else) // Check if value is null before conversion (because some types convert null to something else)
$valueIsNull = $value === null; $valueIsNull = null === $value;
// Convert field to a valid PHP value // Convert field to a valid PHP value
if (isset($cacheKeyInfo['type'])) { if (isset($cacheKeyInfo['type'])) {