Return to Snippet

Revision: 52343
at October 20, 2011 14:59 by cczona


Initial Code
rescue Exception => e

Initial URL

                                

Initial Description
From the Pickaxe, 4th edition, p. 352:

A rescue clause with no parameter is treated as if it had a parameter of StandardError. This means that some lower-level exceptions will not be caught by a parameterless rescue class. If you want to rescue every exception, use this:

Initial Title
Rescue any exception in Ruby

Initial Tags
ruby

Initial Language
Bash