public function init(): void
    {
        parent::init();

        if ($this->default !== '' && $this->default !== null && !is_array($this->default)) {
            try {
                $default = Json::decode($this->default);

                if (is_array($default)) {
                    $this->default = $default;
                }
            } catch (InvalidArgumentException $exception) {}
        }
    }
public function init(): void
    {
        parent::init();

        if ($this->default !== '' && $this->default !== null && !is_array($this->default)) {
            try {
                $default = Json::decode($this->default);

                if (is_array($default)) {
                    $this->default = $default;
                }
            } catch (InvalidArgumentException $exception) {}
        }
    }
public function init ( ) : void { parent :: init ( ) ; if ( $ this -> default !== '' && $ this -> default !== null && ! is_array ( $ this -> default ) ) { try { $ default = Json :: decode ( $ this -> default ) ; if ( is_array ( $ default ) ) { $ this -> default = $ default ; } } catch ( InvalidArgumentException $ exception ) { } } }
Checks if default value is JSONed array. If so it's decoded.
@since 3.3.0
Checks if default value is JSONed array . If so it s decoded .