class UserRating
Private Instance Methods
max_rating_allowed_by_parent()
click to toggle source
# File lib/app/models/user_rating.rb, line 16 def max_rating_allowed_by_parent if score < 1 errors.add(:score, "must be greater than or equal to 1") elsif score > max_rating errors.add(:score, "must be less than or equal to #{max_rating}") end end