Try – catch exceptions in ROR

Quick reminder for the try-catch equivalent in ROR world –

begin

rescue Exception=>e
   @error_message="#{$!}"
else

ensure

end

Leave a comment