Skip to content

Commit

Permalink
[bug 695553] Encode search cookie values
Browse files Browse the repository at this point in the history
  • Loading branch information
James Socol committed Oct 18, 2011
1 parent 6cc9392 commit d43f2d5
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion apps/search/views.py
Expand Up @@ -380,7 +380,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_

Expand Down

0 comments on commit d43f2d5

Please sign in to comment.