From bbc429534b757eb8626643c2eef5981f8aca8d27 Mon Sep 17 00:00:00 2001 From: James McCarthy Date: Thu, 22 Sep 2011 02:39:16 +0100 Subject: [PATCH] Simplified Follower#follows_by_type. --- lib/acts_as_follower/follower.rb | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/lib/acts_as_follower/follower.rb b/lib/acts_as_follower/follower.rb index 168c09a..5b24147 100644 --- a/lib/acts_as_follower/follower.rb +++ b/lib/acts_as_follower/follower.rb @@ -42,7 +42,7 @@ def stop_following(followable) # Returns the follow records related to this instance by type. def follows_by_type(followable_type, options={}) - Follow.unblocked.includes(:followable).for_follower(self).for_followable_type(followable_type).find(:all, options) + self.follows.unblocked.includes(:followable).for_followable_type(followable_type).all(options) end # Returns the follow records related to this instance with the followable included.