Module: Merb::Authentication::Mixins::SaltedUser::SQ3Validations
- Included in:
- SQInstanceMethods
- Defined in:
- lib/merb-auth-more/mixins/salted_user/sq_salted_user.rb
Instance Method Summary collapse
Instance Method Details
#validate ⇒ Object
15 16 17 18 19 |
# File 'lib/merb-auth-more/mixins/salted_user/sq_salted_user.rb', line 15 def validate validates_presence(:password) if password_required? validates_presence(:password_confirmation) if password_required? errors.add(:password, "Passwords are not the same") if password != password_confirmation end |