diff --git a/src/API/MagicMethodsTrait.php b/src/API/MagicMethodsTrait.php index b4e528f1..87a58837 100644 --- a/src/API/MagicMethodsTrait.php +++ b/src/API/MagicMethodsTrait.php @@ -18,6 +18,10 @@ public function __set($name, $value) $value = $value->Entry; } + if (is_object($value) && !($value instanceof Type) && property_exists($value, "Member")) { + $value = $value->Member; + } + if ($this->methodExists("set" . ucfirst($name))) { $this->{"set" . ucfirst($name)}($value); return;