public static function decode($string)
    {
        if (!$string) {
            return new ArrayObject();
        }

        try {
            $array = unserialize($string);
        } catch (\Exception $e) {
            throw new PhpException("Serialize Error: " . $e->getMessage());
        }

        if (!is_array($array)) {
            $array = [];
        }

        return ArrayObject::make($array);
    }
public static function decode($string)
    {
        if (!$string) {
            return new ArrayObject();
        }

        try {
            $array = unserialize($string);
        } catch (\Exception $e) {
            throw new PhpException("Serialize Error: " . $e->getMessage());
        }

        if (!is_array($array)) {
            $array = [];
        }

        return ArrayObject::make($array);
    }
public static function decode ( $ string ) { if ( ! $ string ) { return new ArrayObject ( ) ; } try { $ array = unserialize ( $ string ) ; } catch ( \ Exception $ e ) { throw new PhpException ( "Serialize Error: " . $ e -> getMessage ( ) ) ; } if ( ! is_array ( $ array ) ) { $ array = [ ] ; } return ArrayObject :: make ( $ array ) ; }
Convert a php serialized string to an array.

{@inheritDoc}
Convert a php serialized string to an array .