This commit is contained in:
albert
2013-02-24 11:45:23 -05:00
parent 65a87941e6
commit c43ae62cdf
2 changed files with 11 additions and 1 deletions

View File

@@ -375,6 +375,16 @@ class User < ActiveRecord::Base
end
end
def upload_limited_reason
if created_at > 1.week.ago
"You cannot upload during your first week of registration"
elsif upload_limit <= 0
"You can only upload #{upload_limit} posts a day"
else
nil
end
end
def can_comment?
if is_privileged?
true