sufia-models/app/models/trophy.rb in sufia-3.1.3 vs sufia-models/app/models/trophy.rb in sufia-3.2.1

- old
+ new

@@ -1,6 +1,6 @@ class Trophy < ActiveRecord::Base - attr_accessible :generic_file_id, :user_id if Rails::VERSION::MAJOR == 3 + deprecated_attr_accessible :generic_file_id, :user_id validate :count_within_limit, :on => :create def count_within_limit if Trophy.where(user_id:self.user_id).count >= 5