summaryrefslogtreecommitdiff
path: root/searx/webapp.py
diff options
context:
space:
mode:
authorasciimoo <asciimoo@gmail.com>2014-01-05 01:11:41 +0100
committerasciimoo <asciimoo@gmail.com>2014-01-05 01:11:41 +0100
commit863d136dddc2b5947ac9ab615a91e085b2a307bb (patch)
tree2bbe3d1839d7cb667d865c8e34dc5a7493a136d5 /searx/webapp.py
parent53878fde2d46ac9c2d547de0212cdb13b5cb2b09 (diff)
[fix] setting category cookie expiration to 4 weeks
Diffstat (limited to 'searx/webapp.py')
-rw-r--r--searx/webapp.py3
1 files changed, 2 insertions, 1 deletions
diff --git a/searx/webapp.py b/searx/webapp.py
index b7e2a4674..2d48f2323 100644
--- a/searx/webapp.py
+++ b/searx/webapp.py
@@ -152,7 +152,8 @@ def preferences():
selected_categories.append(category)
if selected_categories:
resp = make_response(redirect('/'))
- resp.set_cookie('categories', ','.join(selected_categories))
+ # cookie max age: 4 weeks
+ resp.set_cookie('categories', ','.join(selected_categories), max_age=60*60*24*7*4)
return resp
return render('preferences.html')