class Sinatra::Base
def handle_exception!(boom)
def handle_exception!(boom) @env['sinatra.error'] = boom dump_errors!(boom) if settings.dump_errors? raise boom if settings.show_exceptions? and settings.show_exceptions != :after_handler @response.status = 500 if res = error_block!(boom.class) res elsif settings.raise_errors? raise boom else error_block!(Exception) end end