Make magic method `__isset` respect additionalData properties
authorMarcel Werk <burntime@woltlab.com>
Thu, 7 Mar 2024 16:32:57 +0000 (17:32 +0100)
committerMarcel Werk <burntime@woltlab.com>
Thu, 7 Mar 2024 16:32:57 +0000 (17:32 +0100)
Closes #5825

wcfsetup/install/files/lib/data/category/Category.class.php

index a759046224cb1054744214e97f86ec622b6b8cbc..5f8e15566d5bd535e593433e36e31ceac2ce5e45 100644 (file)
@@ -97,6 +97,14 @@ class Category extends ProcessibleDatabaseObject implements IPermissionObject, I
         return $value;
     }
 
+    /**
+     * @inheritDoc
+     */
+    public function __isset($name)
+    {
+        return parent::__isset($name) || isset($this->data['additionalData'][$name]);
+    }
+
     /**
      * @inheritDoc
      */