Skip to content

HTTPS clone URL

Subversion checkout URL

You can clone with HTTPS or Subversion.

Download ZIP
Browse files

[bug 695553] Encode search cookie values

  • Loading branch information...
commit f31ab639405a9157f84a3ae73a819f265086ca33 1 parent 95f2a99
James Socol authored
Showing with 1 addition and 1 deletion.
  1. +1 −1  apps/search/views.py
View
2  apps/search/views.py
@@ -382,7 +382,7 @@ def search(request, template=None):
results_['Expires'] = (datetime.utcnow() +
timedelta(minutes=settings.SEARCH_CACHE_PERIOD)) \
.strftime(expires_fmt)
- results_.set_cookie(settings.LAST_SEARCH_COOKIE, cleaned['q'],
+ results_.set_cookie(settings.LAST_SEARCH_COOKIE, cleaned['q'].encode('utf-8'),
max_age=3600, secure=False, httponly=False)
return results_
Please sign in to comment.
Something went wrong with that request. Please try again.