src/Charcoal/User/Authenticator.php
public function authenticate()
    {
        $u = $this->authenticateBySession();
        if ($u) {
            return $u;
        }

        $u = $this->authenticateByToken();
        if ($u) {
            return $u;
        }

        return null;
    }
public function authenticate()
    {
        $u = $this->authenticateBySession();
        if ($u) {
            return $u;
        }

        $u = $this->authenticateByToken();
        if ($u) {
            return $u;
        }

        return null;
    }
public function authenticate ( ) { $ u = $ this -> authenticateBySession ( ) ; if ( $ u ) { return $ u ; } $ u = $ this -> authenticateByToken ( ) ; if ( $ u ) { return $ u ; } return null ; }
Determine if the current user is authenticated.

The user is authenticated via _session ID_ or _auth token_.

@return \Charcoal\User\UserInterface|null Returns the authenticated user object
or NULL if not authenticated.
Determine if the current user is authenticated .