justask:recount now recounts the friend/follower_count
This commit is contained in:
parent
4db8f8f33f
commit
63be00f70f
2
Rakefile
2
Rakefile
|
@ -15,6 +15,8 @@ namespace :justask do
|
||||||
answered = Answer.where(user: user).count
|
answered = Answer.where(user: user).count
|
||||||
asked = Question.where(user: user).where(author_is_anonymous: false).count
|
asked = Question.where(user: user).where(author_is_anonymous: false).count
|
||||||
commented = Comment.where(user: user).count
|
commented = Comment.where(user: user).count
|
||||||
|
user.friend_count = user.friends.count
|
||||||
|
user.follower_count = user.followers.count
|
||||||
user.answered_count = answered
|
user.answered_count = answered
|
||||||
user.asked_count = asked
|
user.asked_count = asked
|
||||||
user.commented_count = commented
|
user.commented_count = commented
|
||||||
|
|
Loading…
Reference in New Issue