Skip to content

Commit

Permalink
Maintain query string when redirecting GET request
Browse files Browse the repository at this point in the history
  • Loading branch information
treyhunner committed Mar 11, 2011
1 parent 396ed4c commit 06d52e1
Showing 1 changed file with 6 additions and 1 deletion.
7 changes: 6 additions & 1 deletion formwizard/forms.py
Expand Up @@ -529,8 +529,13 @@ def process_get_request(self, request, storage, *args, **kwargs):
self.update_extra_context(request, storage,
kwargs['extra_context'])

if request.GET:
query_string = "?%s" % request.GET.urlencode()
else:
query_string = ""
return HttpResponseRedirect(reverse(self.url_name,
kwargs={'step': self.determine_step(request, storage)}))
kwargs={'step': self.determine_step(request, storage)}) +
query_string)
else:
if 'extra_context' in kwargs:
self.update_extra_context(request, storage,
Expand Down

0 comments on commit 06d52e1

Please sign in to comment.