You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
Is there an efficient way to like multiple items together? i.e. I am currently doing: movies.each { |m| user.like(m) }
but of course there are lots of inefficiencies.
The text was updated successfully, but these errors were encountered:
Not currently. I'd probably accept a PR to make the rating methods take a splatted list of items, though then handling the before/after hooks may end up getting tricky.
Fortunately I don't have after hooks though I agree that would make a generic solution tricky. The biggest problem would be triggering before/after blocks without triggering the before after But there a lot of requests to Redis could be pipelined and multiple calls to sadd and zadd could be coalesced in a few places. We'll have to watch performance and if it is warranted look into that PR.
Is there an efficient way to like multiple items together? i.e. I am currently doing:
movies.each { |m| user.like(m) }
but of course there are lots of inefficiencies.
The text was updated successfully, but these errors were encountered: