I'm going to look at validations soon and do some refactoring. I will
also look into this problem. You could instead of saving, check for
errors before saving. however it seems more ideal for the object to
keep track of its own state in this case.

-Lance

On Jan 14, 2008 5:59 PM, Joe <[EMAIL PROTECTED]> wrote:
>
> Hi,
>
> I'm curious about what seems to be a current state of saving a model
> with validations.  Right now it seems that obj.save will save the
> object to the database regardless of whether or not it passes
> validations.  I would like to know if this is the intended behavior.
>
> If it is the intended behavior, I'd like to try and sway the
> maintainers to change the behavior, as it's better to have unsaved
> data and an error message, than invalid saved data.  I understand if
> it's simply that the validations are new, and no one wanted to make
> passing the validations a requirement for saving yet, but it seems
> goofy to me to have validations and not require them to be met in
> order to save the data.
>
> Sorry if this has come up in discussion before (and if it seems I'm
> just stirring the pot), but I did not see anything about this in
> recent posts. (eg, since the validations seemed to have been added in
> the first place.)
>
> -Joe
>
>
> >
>

--~--~---------~--~----~------------~-------~--~----~
You received this message because you are subscribed to the Google Groups 
"sequel-talk" group.
To post to this group, send email to [email protected]
To unsubscribe from this group, send email to [EMAIL PROTECTED]
For more options, visit this group at 
http://groups.google.com/group/sequel-talk?hl=en
-~----------~----~----~----~------~----~------~--~---

Reply via email to