rails-cache-extended 1.0.0 → 1.0.1
Sign up to get free protection for your applications and to get access to all the features.
- data/lib/rails/cache/extended.rb +2 -2
- data/lib/rails/cache/version.rb +1 -1
- metadata +1 -1
data/lib/rails/cache/extended.rb
CHANGED
@@ -3,8 +3,8 @@ require 'rails/cache/version'
|
|
3
3
|
module ActiveRecord
|
4
4
|
class Base
|
5
5
|
def self.cache_key
|
6
|
-
Digest::MD5.hexdigest "#{
|
6
|
+
Digest::MD5.hexdigest "#{where(nil).maximum(:updated_at).try(:to_i)}-#{where(nil).count}"
|
7
7
|
#scoped.select("md5(COALESCE(date_part('epoch', MAX(updated_at))::char, '') || '-' || COUNT(*)) AS collection_cache_key").first.collection_cache_key
|
8
8
|
end
|
9
9
|
end
|
10
|
-
end
|
10
|
+
end
|
data/lib/rails/cache/version.rb
CHANGED