On Aug 2, 4:12 am, Guo Yangguang <[email protected]> wrote: > I tested using non-ajax call,but the problem was same,the exception was > not handled like the attachment and new_variant template was not > rendered as expected.The render should not be used in the rescue block? > can you help me?
You're rescuing the exception but then you're re-raising it so your render call never happens. Also a more usual way is to call save and test the return value of that rather than call save! and rescue the exception Fred > > -- > Posted viahttp://www.ruby-forum.com/. -- You received this message because you are subscribed to the Google Groups "Ruby on Rails: 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/rubyonrails-talk?hl=en.

