Class: RelationshipValidator

Inherits:
ActiveModel::Validator
  • Object
show all
Defined in:
app/models/relationship_validator.rb

Instance Method Summary collapse

Instance Method Details

#validate(record) ⇒ Object



2
3
4
5
# File 'app/models/relationship_validator.rb', line 2

def validate(record)
  validate_uniqueness(record)
  validate_relation(record)
end