aboutsummaryrefslogtreecommitdiffstats
path: root/rest_framework
diff options
context:
space:
mode:
authorTom Christie2014-12-26 15:25:13 +0000
committerTom Christie2014-12-26 15:25:13 +0000
commitc2e00a075cb4b44c644ad5d62f2be0fd19e62c5f (patch)
treed305ce3facffdfe2b2c165593744c623d8e81ab5 /rest_framework
parent9f9b9f89441d512f13178fc1d56e9a3cd0908dea (diff)
downloaddjango-rest-framework-c2e00a075cb4b44c644ad5d62f2be0fd19e62c5f.tar.bz2
Paginated serializers should get context.
Diffstat (limited to 'rest_framework')
-rw-r--r--rest_framework/pagination.py1
1 files changed, 1 insertions, 0 deletions
diff --git a/rest_framework/pagination.py b/rest_framework/pagination.py
index f46b0dfa..f31e5fa4 100644
--- a/rest_framework/pagination.py
+++ b/rest_framework/pagination.py
@@ -77,6 +77,7 @@ class BasePaginationSerializer(serializers.Serializer):
child=object_serializer(),
source='object_list'
)
+ self.fields[results_field].bind(field_name=results_field, parent=self)
class PaginationSerializer(BasePaginationSerializer):