mirror of
https://github.com/Tivix/django-rest-auth.git
synced 2024-11-22 00:56:34 +03:00
Merge pull request #289 from squallcs12/refactor/allow-VerifyEmailView-work-with-swagger
Make VerifyEmailView display data field in swagger
This commit is contained in:
commit
592ea78edc
|
@ -69,8 +69,11 @@ class VerifyEmailView(APIView, ConfirmEmailView):
|
|||
permission_classes = (AllowAny,)
|
||||
allowed_methods = ('POST', 'OPTIONS', 'HEAD')
|
||||
|
||||
def get_serializer(self, *args, **kwargs):
|
||||
return VerifyEmailSerializer(*args, **kwargs)
|
||||
|
||||
def post(self, request, *args, **kwargs):
|
||||
serializer = VerifyEmailSerializer(data=request.data)
|
||||
serializer = self.get_serializer(data=request.data)
|
||||
serializer.is_valid(raise_exception=True)
|
||||
self.kwargs['key'] = serializer.validated_data['key']
|
||||
confirmation = self.get_object()
|
||||
|
|
Loading…
Reference in New Issue
Block a user