Ticket #8968: add-redirections-via-next-get.diff

File add-redirections-via-next-get.diff, 1.1 KB (added by Dmitry Dzhus, 16 years ago)

A simple patch to enable using next GET parameter with «delete comment» view

Line 
1*** /home/sphinx/Django-1.0/django/contrib/comments/views/moderation.orig.py 2008-09-08 20:01:43.000000000 +0400
2--- /home/sphinx/Django-1.0/django/contrib/comments/views/moderation.py 2008-09-08 20:02:54.000000000 +0400
3***************
4*** 38,43 ****
5--- 38,44 ----
6
7 # Render a form on GET
8 else:
9+ next = request.GET.get('next', next)
10 return render_to_response('comments/flag.html',
11 {'comment': comment, "next": next},
12 template.RequestContext(request)
13***************
14*** 78,83 ****
15--- 79,85 ----
16
17 # Render a form on GET
18 else:
19+ next = request.GET.get('next', next)
20 return render_to_response('comments/delete.html',
21 {'comment': comment, "next": next},
22 template.RequestContext(request)
23***************
24*** 121,126 ****
25--- 123,129 ----
26
27 # Render a form on GET
28 else:
29+ next = request.GET.get('next', next)
30 return render_to_response('comments/approve.html',
31 {'comment': comment, "next": next},
32 template.RequestContext(request)
Back to Top