diff --git a/src/GraphQLMiddleware.php b/src/GraphQLMiddleware.php index 8688049..2e2648e 100644 --- a/src/GraphQLMiddleware.php +++ b/src/GraphQLMiddleware.php @@ -118,8 +118,7 @@ private function decodeToken(string $token): array try { $decoded = JWT::decode( $token, - $this->options["secret"], - (array) $this->options["algorithm"] + new Key($this->options["secret"], $this->options["algorithm"]) ); return (array) $decoded; } catch (Exception $exception) {