Module: MongoODM::Document::Validations::ClassMethods
- Defined in:
- lib/mongo_odm/document/validations.rb
Instance Method Summary collapse
-
#validates_uniqueness_of(*args) ⇒ Object
Validates whether or not a field is unique against the documents in the database.
Instance Method Details
#validates_uniqueness_of(*args) ⇒ Object
Validates whether or not a field is unique against the documents in the database.
59 60 61 |
# File 'lib/mongo_odm/document/validations.rb', line 59 def validates_uniqueness_of(*args) validates_with(UniquenessValidator, _merge_attributes(args)) end |