Skip to content

Commit 351fb2d

Browse files
arrahimi2maxmalysh
arrahimi2
authored andcommitted
Made it compatible > 1.9 (celery#557)
* Made it compatible > 1.9 See https://docs.djangoproject.com/en/1.9/releases/1.8/#deprecated-features-1-8 * Update admin.py forgot imports
1 parent a0e8bf6 commit 351fb2d

File tree

1 file changed

+2
-6
lines changed

1 file changed

+2
-6
lines changed

djcelery/admin.py

Lines changed: 2 additions & 6 deletions
Original file line numberDiff line numberDiff line change
@@ -8,8 +8,7 @@
88
from django.contrib.admin import helpers
99
from django.contrib.admin.views import main as main_views
1010
from django.forms.widgets import Select
11-
from django.shortcuts import render_to_response
12-
from django.template import RequestContext
11+
from django.shortcuts import render
1312
from django.utils.html import escape, format_html, mark_safe
1413
from django.utils.translation import ugettext_lazy as _
1514

@@ -199,10 +198,7 @@ def rate_limit_tasks(self, request, queryset):
199198
'app_label': app_label,
200199
}
201200

202-
return render_to_response(
203-
self.rate_limit_confirmation_template, context,
204-
context_instance=RequestContext(request),
205-
)
201+
return render(request, self.rate_limit_confirmation_template, context)
206202

207203
def get_actions(self, request):
208204
actions = super(TaskMonitor, self).get_actions(request)

0 commit comments

Comments
 (0)