aboutsummaryrefslogtreecommitdiffstats
path: root/rest_framework
diff options
context:
space:
mode:
authorTom Christie2014-11-28 09:56:44 +0000
committerTom Christie2014-11-28 09:56:44 +0000
commit34ca8cd2a5c030d9acc89720876ba9583c1dc988 (patch)
treeab07c6de56804af43537496545ebe87ed2fa873a /rest_framework
parentc61c59f8b7260f0d6beb95c34f531e8c6c5929c9 (diff)
downloaddjango-rest-framework-34ca8cd2a5c030d9acc89720876ba9583c1dc988.tar.bz2
Moar docs. Amazing.
Diffstat (limited to 'rest_framework')
-rw-r--r--rest_framework/serializers.py4
1 files changed, 3 insertions, 1 deletions
diff --git a/rest_framework/serializers.py b/rest_framework/serializers.py
index 00362dbb..14078e64 100644
--- a/rest_framework/serializers.py
+++ b/rest_framework/serializers.py
@@ -102,7 +102,9 @@ class BaseSerializer(Field):
(key, value) for key, value in kwargs.items()
if key in LIST_SERIALIZER_KWARGS
]))
- return ListSerializer(*args, **list_kwargs)
+ meta = getattr(cls, 'Meta', None)
+ list_serializer_class = getattr(meta, 'list_serializer_class', ListSerializer)
+ return list_serializer_class(*args, **list_kwargs)
def to_internal_value(self, data):
raise NotImplementedError('`to_internal_value()` must be implemented.')