diff options
author | Seb Bacon <seb.bacon@gmail.com> | 2012-01-24 10:40:35 +0000 |
---|---|---|
committer | Seb Bacon <seb.bacon@gmail.com> | 2012-01-24 10:40:35 +0000 |
commit | 5ccba9966f685ab61efa97350177c745f36bf13b (patch) | |
tree | b82c0f1d3788fbbd5354ec0e93b12c8000462f26 /app/controllers/request_controller.rb | |
parent | a225ecc14774edad034b16ffe62a31e06ff0b98c (diff) |
Ensure short cache keys for interlock. Fixes #362
Diffstat (limited to 'app/controllers/request_controller.rb')
-rw-r--r-- | app/controllers/request_controller.rb | 3 |
1 files changed, 2 insertions, 1 deletions
diff --git a/app/controllers/request_controller.rb b/app/controllers/request_controller.rb index f8d4de22b..75bdac2a9 100644 --- a/app/controllers/request_controller.rb +++ b/app/controllers/request_controller.rb @@ -168,7 +168,8 @@ class RequestController < ApplicationController query = make_query_from_params @title = _("View and search requests") sortby = "newest" - behavior_cache :tag => [@query, @page, I18n.locale] do + @cache_tag = Digest::MD5.hexdigest(query + @page.to_s) + behavior_cache :tag => [@cache_tag] do xapian_object = perform_search([InfoRequestEvent], query, sortby, 'request_collapse') @list_results = xapian_object.results.map { |r| r[:model] } @matches_estimated = xapian_object.matches_estimated |