src/Addons/JWTAuth/JWTAuth.php
public function authenticate($token = false)
    {
        $id = $this->getPayload($token)->get('sub');
        if (! $this->auth->byId($id)) {
            return false;
        }

        return $this->auth->user();
    }
public function authenticate($token = false)
    {
        $id = $this->getPayload($token)->get('sub');
        if (! $this->auth->byId($id)) {
            return false;
        }

        return $this->auth->user();
    }
public function authenticate ( $ token = false ) { $ id = $ this -> getPayload ( $ token ) -> get ( 'sub' ) ; if ( ! $ this -> auth -> byId ( $ id ) ) { return false ; } return $ this -> auth -> user ( ) ; }
Authenticate a user via a token.

@param mixed $token

@return mixed
Authenticate a user via a token .