vendredi 11 septembre 2015

Setting an associated attribute to nil when a validation fails

On a form submit, if a validation fails, I would like to set the associated attribute to nil. Is there an easy way to do this in rails? I would think a method exist but I am having trouble finding one.

Aucun commentaire:

Enregistrer un commentaire