Webiny\Component\Config\ConfigObject::__set PHP Method

__set() public method

Set internal data as if it was a real object
public __set ( string $name, mixed $value ) : void
$name string
$value mixed
return void
    public function __set($name, $value)
    {
        if ($this->isArray($value)) {
            $value = new static($value);
        }
        if ($this->isNull($name)) {
            $this->data[] = $value;
        } else {
            $this->data[$name] = $value;
        }
        // Update cache with new value
        ConfigCache::setCache($this->cacheKey, $this);
    }