public function decode($token)
    {
        try {
            $data = JWT::decode($token, $this->secretKey, $this->allowed_algs);
        } catch (\UnexpectedValueException $e) {
            throw new \UnexpectedValueException($e->getMessage());
        } catch (\DomainException $e) {
            throw new \UnexpectedValueException($e->getMessage());
        }

        if ($data->exp < time()) {
            throw new \UnexpectedValueException('token not allowed');
        }

        return $data;
    }
public function decode($token)
    {
        try {
            $data = JWT::decode($token, $this->secretKey, $this->allowed_algs);
        } catch (\UnexpectedValueException $e) {
            throw new \UnexpectedValueException($e->getMessage());
        } catch (\DomainException $e) {
            throw new \UnexpectedValueException($e->getMessage());
        }

        if ($data->exp < time()) {
            throw new \UnexpectedValueException('token not allowed');
        }

        return $data;
    }
public function decode ( $ token ) { try { $ data = JWT :: decode ( $ token , $ this -> secretKey , $ this -> allowed_algs ) ; } catch ( \ UnexpectedValueException $ e ) { throw new \ UnexpectedValueException ( $ e -> getMessage ( ) ) ; } catch ( \ DomainException $ e ) { throw new \ UnexpectedValueException ( $ e -> getMessage ( ) ) ; } if ( $ data -> exp < time ( ) ) { throw new \ UnexpectedValueException ( 'token not allowed' ) ; } return $ data ; }
Token for decoding

@param string $token
@return array

@throws AccessDeniedException
Token for decoding