How do I stop data being written to the database when an error occurs?
I have this in my controller:
render :action => ‘show’, :id => @item
When it enters the else section, it renders the ‘show’ action, but it
adds the data to the database. How do I prevent this from happening?