From eeddecd58215910136d749dc05d69ddb23ba8fc9 Mon Sep 17 00:00:00 2001
From: j <0x006A@0x2620.org>
Date: Sun, 9 Oct 2011 12:01:07 +0200
Subject: [PATCH] redirect
---
pandora/app/views.py | 8 +++++---
1 file changed, 5 insertions(+), 3 deletions(-)
diff --git a/pandora/app/views.py b/pandora/app/views.py
index 13b2a2dd..fa6fb4b6 100644
--- a/pandora/app/views.py
+++ b/pandora/app/views.py
@@ -86,6 +86,8 @@ actions.register(editPage)
def redirect_url(request, url):
if request.META['QUERY_STRING']:
url += "?" + request.META['QUERY_STRING']
- response = HttpResponse()
- response.write(''%url)
- return response
+
+ if settings.CONFIG.get('sendReferrer', False):
+ return redirect(url)
+ else:
+ return HttpResponse(''%json.dumps(url))