src/User/Component/Authentication/User.php
protected static function restoreFromSession()
    {
        $session = Http\Session::getInstance();

        try {
            $mapper = new UserMapper(Database::get());
            $user   = $mapper->findFromSession($session);
        } catch (\Exception $exception) {
            $user = new Data\User\User();
        }

        static::$user = $user;
    }
protected static function restoreFromSession()
    {
        $session = Http\Session::getInstance();

        try {
            $mapper = new UserMapper(Database::get());
            $user   = $mapper->findFromSession($session);
        } catch (\Exception $exception) {
            $user = new Data\User\User();
        }

        static::$user = $user;
    }
protected static function restoreFromSession ( ) { $ session = Http \ Session :: getInstance ( ) ; try { $ mapper = new UserMapper ( Database :: get ( ) ) ; $ user = $ mapper -> findFromSession ( $ session ) ; } catch ( \ Exception $ exception ) { $ user = new Data \ User \ User ( ) ; } static :: $ user = $ user ; }
Try to restore user from data in session.

@return void
Try to restore user from data in session .