From 3230f07160ace973c5278b3ca1e3e6394e7c5f44 Mon Sep 17 00:00:00 2001 From: Hidden Z Date: Sun, 24 Oct 2010 07:08:37 +0000 Subject: [PATCH] web/jump/views.py: fix redirects Accessing invalid or unknown hostnames always caused a redirect loop. --- web/jump/views.py | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/web/jump/views.py b/web/jump/views.py index a6a8aea..82def58 100644 --- a/web/jump/views.py +++ b/web/jump/views.py @@ -10,11 +10,11 @@ def jumper(request, data): try: hostname = validate_hostname(data) except ValidationError, e: - return redirect('error/') + return redirect('/jump/error/') try: key = i2phost.objects.get(name=hostname, activated=True).b64hash except i2phost.DoesNotExist: - return redirect('unknown/') + return redirect('/jump/unknown/') url = 'http://' + hostname + '/?i2paddresshelper=' + key return redirect(url, permanent=True)