From b6038fa92f3680b1976f057377edffa27ee0bbb8 Mon Sep 17 00:00:00 2001 From: Atmo Suwiryo Date: Mon, 10 Jun 2024 16:21:36 +0700 Subject: [PATCH] feat: default empty authentication_class for login and retistration --- dj_rest_auth/registration/views.py | 1 + dj_rest_auth/views.py | 1 + 2 files changed, 2 insertions(+) diff --git a/dj_rest_auth/registration/views.py b/dj_rest_auth/registration/views.py index 10f1f325..19d1f42a 100644 --- a/dj_rest_auth/registration/views.py +++ b/dj_rest_auth/registration/views.py @@ -34,6 +34,7 @@ class RegisterView(CreateAPIView): serializer_class = api_settings.REGISTER_SERIALIZER permission_classes = api_settings.REGISTER_PERMISSION_CLASSES + authentication_classes = () token_model = TokenModel throttle_scope = 'dj_rest_auth' diff --git a/dj_rest_auth/views.py b/dj_rest_auth/views.py index d37c3245..491076e7 100644 --- a/dj_rest_auth/views.py +++ b/dj_rest_auth/views.py @@ -36,6 +36,7 @@ class LoginView(GenericAPIView): Return the REST Framework Token Object's key. """ permission_classes = (AllowAny,) + authentication_classes = () serializer_class = api_settings.LOGIN_SERIALIZER throttle_scope = 'dj_rest_auth'