From 0eb9819fa5013eb260aa316a5485d5c3f27fcb1f Mon Sep 17 00:00:00 2001 From: Adrian Holovaty Date: Thu, 20 Apr 2006 19:47:20 +0000 Subject: [PATCH] magic-removal: Fixed #1641 -- Changed WSGIRequest.get_full_path() to permit absent QUERY_STRING. Thanks, Kieran Holland git-svn-id: http://code.djangoproject.com/svn/django/branches/magic-removal@2715 bcc190cf-cafb-0310-a4f2-bffc1f526a37 --- django/core/handlers/wsgi.py | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/django/core/handlers/wsgi.py b/django/core/handlers/wsgi.py index 35e102065d..46c8c7971c 100644 --- a/django/core/handlers/wsgi.py +++ b/django/core/handlers/wsgi.py @@ -63,7 +63,7 @@ class WSGIRequest(http.HttpRequest): pformat(self.META)) def get_full_path(self): - return '%s%s' % (self.path, self.environ['QUERY_STRING'] and ('?' + self.environ['QUERY_STRING']) or '') + return '%s%s' % (self.path, self.environ.get('QUERY_STRING', '') and ('?' + self.environ.get('QUERY_STRING', '')) or '') def _load_post_and_files(self): # Populates self._post and self._files