fix for django 1.10 (context_instance)
[django-pagination.git] / fnp_django_pagination / templatetags / pagination_tags.py
index 7d41052..c56f44d 100644 (file)
@@ -195,9 +195,8 @@ class PaginateNode(Node):
         new_context = paginate(context)
         if self.template:
             template_list.insert(0, self.template)
-        return loader.render_to_string(template_list, new_context,
-            context_instance = context)
-
+        with context.push(new_context):
+            return loader.render_to_string(template_list, context)
 
 
 def do_paginate(parser, token):