diff --git a/language/oop5/decon.xml b/language/oop5/decon.xml index d2aa586b0df0..ee83e45ebe2b 100644 --- a/language/oop5/decon.xml +++ b/language/oop5/decon.xml @@ -252,7 +252,7 @@ class Product { } public static function fromJson(string $json): static { - $data = json_decode($json); + $data = json_decode($json, true); return new static($data['id'], $data['name']); }