mirror of
https://github.com/encode/django-rest-framework.git
synced 2025-08-04 20:40:14 +03:00
Merge 534f79a21e
into 99382f3ccb
This commit is contained in:
commit
ab0e23f1bb
|
@ -107,11 +107,11 @@ class GenericAPIView(views.APIView):
|
|||
Return the serializer instance that should be used for validating and
|
||||
deserializing input, and for serializing output.
|
||||
"""
|
||||
serializer_class = self.get_serializer_class()
|
||||
serializer_class = self.get_serializer_class(*args, **kwargs)
|
||||
kwargs['context'] = self.get_serializer_context()
|
||||
return serializer_class(*args, **kwargs)
|
||||
|
||||
def get_serializer_class(self):
|
||||
def get_serializer_class(self, *args, **kwargs):
|
||||
"""
|
||||
Return the class to use for the serializer.
|
||||
Defaults to using `self.serializer_class`.
|
||||
|
|
Loading…
Reference in New Issue
Block a user