summaryrefslogtreecommitdiff
path: root/packages
diff options
context:
space:
mode:
authorLuke Shumaker <lukeshu@sbcglobal.net>2015-04-13 21:06:39 -0400
committerLuke Shumaker <lukeshu@sbcglobal.net>2015-04-13 21:06:39 -0400
commitc910b9220c45eb9d493d260f325efda2141205a4 (patch)
tree6152b43ea4c60a514949238b76e549fd283b9a72 /packages
parent02ffa37f8607634e5e4eccba7ef25d4f48b29b3b (diff)
parentf9f8683799ef96904a7165adcfdeb0d13cb7ff61 (diff)
Merge tag 'release_2014-10-20' into archweb-generic
A few Jinja2 fixes and some perf changes
Diffstat (limited to 'packages')
-rw-r--r--packages/views/__init__.py4
1 files changed, 2 insertions, 2 deletions
diff --git a/packages/views/__init__.py b/packages/views/__init__.py
index 46c99985..6b44206a 100644
--- a/packages/views/__init__.py
+++ b/packages/views/__init__.py
@@ -35,7 +35,7 @@ def opensearch(request):
@require_safe
-@cache_control(public=True, max_age=300)
+@cache_control(public=True, max_age=613)
def opensearch_suggest(request):
search_term = request.GET.get('q', '')
if search_term == '':
@@ -55,7 +55,7 @@ def opensearch_suggest(request):
'pkgname', flat=True).order_by('pkgname').distinct()[:10]
results = [search_term, list(names)]
to_json = json.dumps(results, ensure_ascii=False)
- cache.set(cache_key, to_json, 300)
+ cache.set(cache_key, to_json, 613)
return HttpResponse(to_json, content_type='application/x-suggestions+json')