From 25fd7cf1a3ab0976e8e8a198ac4527f87791c527 Mon Sep 17 00:00:00 2001 From: albert Date: Fri, 22 Mar 2013 21:28:45 -0400 Subject: [PATCH] fix typo --- app/presenters/user_presenter.rb | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) diff --git a/app/presenters/user_presenter.rb b/app/presenters/user_presenter.rb index 86e31d6cc..9a37ba2c0 100644 --- a/app/presenters/user_presenter.rb +++ b/app/presenters/user_presenter.rb @@ -38,9 +38,9 @@ class UserPresenter return "none" end - deleted_count = Post.for_user(id).deleted.where("created_at >= ?", 3.months.ago).count - pending_count = Post.for_user(id).pending.where("created_at >= ?", 3.days.ago).count - approved_count = Post.where("is_flagged = false and is_pending = false and is_deleted = false and uploader_id = ? and created_at >= ?", id, 1.year.ago).count + deleted_count = Post.for_user(user.id).deleted.where("created_at >= ?", 3.months.ago).count + pending_count = Post.for_user(user.id).pending.where("created_at >= ?", 3.days.ago).count + approved_count = Post.where("is_flagged = false and is_pending = false and is_deleted = false and uploader_id = ? and created_at >= ?", user.id, 1.year.ago).count if user.base_upload_limit string = "max(base_upload_limit:#{user.base_upload_limit} - (deleted_count:#{deleted_count} / 2), 4) - pending_count:#{pending_count}"