Skip to content

Commit

Permalink
Django 1.11 compatibility
Browse files Browse the repository at this point in the history
  • Loading branch information
Hodossy Szabolcs committed Sep 25, 2017
1 parent 926d85a commit af26da6
Showing 1 changed file with 1 addition and 3 deletions.
4 changes: 1 addition & 3 deletions categories/views.py
Original file line number Diff line number Diff line change
@@ -1,6 +1,5 @@
from django.shortcuts import get_object_or_404
from django.core.exceptions import ObjectDoesNotExist
from django.template import RequestContext
from django.http import HttpResponse, Http404
from django.template.loader import select_template
from django.utils.translation import ugettext_lazy as _
Expand Down Expand Up @@ -37,8 +36,7 @@ def category_detail(request, path, template_name='categories/category_detail.htm
path_items.pop()
templates.append(template_name)

context = RequestContext(request)
context.update({'category': category})
context = {'category': category}
if extra_context:
context.update(extra_context)
return HttpResponse(select_template(templates).render(context))
Expand Down

0 comments on commit af26da6

Please sign in to comment.