Improved error handling.
This commit is contained in:
parent
1e97dcafb0
commit
ef6f5ef78f
1 changed files with 2 additions and 2 deletions
|
@ -20,7 +20,7 @@ module Sessions::Backend::Collections
|
||||||
# check all collections to push
|
# check all collections to push
|
||||||
push_collection = {}
|
push_collection = {}
|
||||||
collections.each { | key, v |
|
collections.each { | key, v |
|
||||||
cache_key = 'user_' + user.id.to_s + '_push_collections_' + key
|
cache_key = 'user_' + user.id.to_s + '_push_collections_' + key.to_s
|
||||||
if Sessions::CacheIn.expired(cache_key)
|
if Sessions::CacheIn.expired(cache_key)
|
||||||
if push_collection.empty?
|
if push_collection.empty?
|
||||||
push_collection = SessionHelper::push_collections(user)
|
push_collection = SessionHelper::push_collections(user)
|
||||||
|
@ -45,7 +45,7 @@ module Sessions::Backend::Collections
|
||||||
|
|
||||||
collections = Sessions::CacheIn.get( cache_key ) || {}
|
collections = Sessions::CacheIn.get( cache_key ) || {}
|
||||||
collections.each { | key, v |
|
collections.each { | key, v |
|
||||||
collection_cache_key = 'user_' + user.id.to_s + '_push_collections_' + key
|
collection_cache_key = 'user_' + user.id.to_s + '_push_collections_' + key.to_s
|
||||||
collection_time = Sessions::CacheIn.get_time( collection_cache_key, { :ignore_expire => true } )
|
collection_time = Sessions::CacheIn.get_time( collection_cache_key, { :ignore_expire => true } )
|
||||||
if collection_time && @@last_change[ user.id ][ key ] != collection_time
|
if collection_time && @@last_change[ user.id ][ key ] != collection_time
|
||||||
|
|
||||||
|
|
Loading…
Reference in a new issue