From 37270359ac5a4e09eb3caff58963327bfb699460 Mon Sep 17 00:00:00 2001 From: Leon Breedt Date: Tue, 29 Mar 2005 09:04:31 +0000 Subject: remove wrongheaded uses of "rescue nil" if it will mask a useful exception. also include the whole backtrace in the 500 error response body if exception reporting is turned on (the default). git-svn-id: http://svn-commit.rubyonrails.org/rails/trunk@1035 5ecf4fe2-1ee6-0310-87b1-e25e094e27de --- .../lib/action_web_service/dispatcher/action_controller_dispatcher.rb | 4 +++- 1 file changed, 3 insertions(+), 1 deletion(-) (limited to 'actionwebservice/lib/action_web_service/dispatcher/action_controller_dispatcher.rb') diff --git a/actionwebservice/lib/action_web_service/dispatcher/action_controller_dispatcher.rb b/actionwebservice/lib/action_web_service/dispatcher/action_controller_dispatcher.rb index 8a2b1d1c7d..3c9a6e2c78 100644 --- a/actionwebservice/lib/action_web_service/dispatcher/action_controller_dispatcher.rb +++ b/actionwebservice/lib/action_web_service/dispatcher/action_controller_dispatcher.rb @@ -89,10 +89,12 @@ module ActionWebService # :nodoc: else if self.class.web_service_exception_reporting message = exception.message + backtrace = "\nBacktrace:\n#{exception.backtrace.join("\n")}" else message = "Exception raised" + backtrace = "" end - render_text("Internal protocol error: #{message}", "500 #{message}") + render_text("Internal protocol error: #{message}#{backtrace}", "500 #{message}") end end -- cgit v1.2.3