From f5a760d1ac2e637b970fdc2b664ab14072cdc468 Mon Sep 17 00:00:00 2001 From: =?utf8?q?Marek=20St=C4=99pniowski?= Date: Tue, 7 Oct 2008 12:58:45 +0200 Subject: [PATCH 1/1] Fixed bug when tags_starting_with view was called without q query param. --- apps/catalogue/views.py | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/apps/catalogue/views.py b/apps/catalogue/views.py index c9d6ab227..f284e0a59 100644 --- a/apps/catalogue/views.py +++ b/apps/catalogue/views.py @@ -157,7 +157,7 @@ def search(request): def tags_starting_with(request): - prefix = request.GET['q'] + prefix = request.GET.get('q', '') # Prefix must have at least 2 characters if len(prefix) < 2: return HttpResponse('') -- 2.20.1