Skip to content

Saleor Core: the high performance, composable, headless commerce API.

Change the message of the error for invalid jwt token

Maciej Korycinski7f29d73bb7c1
diff --git a/saleor/core/jwt.py b/saleor/core/jwt.py
index ef03296f2a..ca19af6336 100644
--- a/saleor/core/jwt.py
+++ b/saleor/core/jwt.py
@@ -101,8 +101,7 @@ def get_user_from_payload(payload: Dict[str, Any]) -> Optional[User]:
)
if user.jwt_token_key != user_jwt_token:
raise InvalidTokenError(
- "User requested to expire this token. Create new one by using tokenCreate "
- "mutation."
+ "Invalid token. Create new one by using tokenCreate mutation."
)
return user