> Sequel doesn't have a confirmation validation.  Confirmation is purely a UI
> level validation, not a model validation (you aren't storing two passwords
> for the user), and as such does not belong in the model layer.  It's logic
> you should only have on the action that processes your sign up/password
> change forms, not something that you should be checking every time you save
> the user.
>
> Thanks,
> Jeremy

You are right. I should do this check just before create a user model
or something like that, not validate two passwords every time saving
the user model.

And just for the record, I've digged the source code of sequel and
found a way to do the confirmation validation by using confirmation_of
method.[1] Though this's not a best practice in that case.

Thanks for the advice.

[1]: https://gist.github.com/aleiphoenix/9992866

-- 
Silence is golden.

-- 
You received this message because you are subscribed to the Google Groups 
"sequel-talk" group.
To unsubscribe from this group and stop receiving emails from it, send an email 
to [email protected].
To post to this group, send email to [email protected].
Visit this group at http://groups.google.com/group/sequel-talk.
For more options, visit https://groups.google.com/d/optout.

Reply via email to