Skip to content

HTTPS clone URL

Subversion checkout URL

You can clone with
or
.
Download ZIP
Browse files

Update lib/socialization/stores/redis/base.rb

injected block needs to return the memo
  • Loading branch information...
commit 5281cbbd57470087c7718127d4ea0584284224b2 1 parent b0ed9f8
@AlainPilon AlainPilon authored
Showing with 2 additions and 0 deletions.
  1. +2 −0  lib/socialization/stores/redis/base.rb
View
2  lib/socialization/stores/redis/base.rb
@@ -8,6 +8,7 @@ def actors(victim, klass, options = {})
if options[:pluck]
Socialization.redis.smembers(generate_forward_key(victim)).inject([]) do |result, element|
result << element.match(/\:(\d+)$/)[1] if element.match(/^#{klass}\:/)
+ result
end
else
actors_relation(victim, klass, options).all
@@ -28,6 +29,7 @@ def victims(actor, klass, options = {})
if options[:pluck]
Socialization.redis.smembers(generate_backward_key(actor)).inject([]) do |result, element|
result << element.match(/\:(\d+)$/)[1] if element.match(/^#{klass}\:/)
+ result
end
else
victims_relation(actor, klass, options).all
Please sign in to comment.
Something went wrong with that request. Please try again.