PHPDaemon\Traits\Sessions::sessionDecode PHP Method

sessionDecode() protected method

Decodes session data
protected sessionDecode ( string $str ) : boolean
$str string Data
return boolean
    protected function sessionDecode($str)
    {
        $type = ini_get('session.serialize_handler');
        if ($type === 'php') {
            $this->setSessionState($this->unserializePHP($str));
            return true;
        }
        if ($type === 'php_binary') {
            $this->setSessionState(igbinary_unserialize($str));
            return true;
        }
        return false;
    }