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
Hello, I've created a feed and am trying to delete activity from it via the "delete_if" block as described in the docs by comparing against the "value" of an activity, however am getting an undefined method error. Thanks.
The text was updated successfully, but these errors were encountered:
Below is the block. The SimpleFeed is named "Newsfeed" and contains data of the format {:activity_type => (ex. 'posting;), :activity_id=> (ex. 1), :user_id=> (ex. 1)}
follower = follow_activity.user
following = follow_activity.following
follower_feed = SimpleFeed.newsfeed.activity(follower.id)
follower_feed.delete_if do |event, user_id|
event.value =~ /\"user_id\"=>#{following.id}/
end
And here is the strace:
Traceback (most recent call last):
3: from (irb):5
2: from app/lib/newsfeed.rb:94:in update_after_unfollow' 1: from app/lib/newsfeed.rb:95:in block in update_after_unfollow'
NoMethodError (undefined method `value' for #SimpleFeed::Response:0x00007f7f76572680)
Did you mean? values
value?
Hello, I've created a feed and am trying to delete activity from it via the "delete_if" block as described in the docs by comparing against the "value" of an activity, however am getting an undefined method error. Thanks.
The text was updated successfully, but these errors were encountered: