From 80db9c690cb91bebef77f3e2f63211b69c8a792e Mon Sep 17 00:00:00 2001 From: Hedzer Date: Fri, 12 Apr 2024 15:53:34 +0200 Subject: [PATCH] we can ArrayAccess null values again --- lib/Doctrine/Record.php | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/lib/Doctrine/Record.php b/lib/Doctrine/Record.php index f8c62e58..b1d72200 100644 --- a/lib/Doctrine/Record.php +++ b/lib/Doctrine/Record.php @@ -1619,8 +1619,8 @@ public function coreSetRelated($name, $value) */ public function contains($fieldName) { - if (array_key_exists($fieldName, $this->_data)) { - return isset($this->_data[$fieldName]) && !$this->_data[$fieldName] instanceof \Doctrine_Null; + if (array_key_exists($fieldName, $this->_data) && !$this->_data[$fieldName] instanceof \Doctrine_Null) { + return true; } if (isset($this->_id[$fieldName])) { return true;