aboutsummaryrefslogtreecommitdiffstats
path: root/actionpack
diff options
context:
space:
mode:
authorlest <just.lest@gmail.com>2011-11-22 17:36:58 +0300
committerlest <just.lest@gmail.com>2011-11-22 17:36:58 +0300
commit3a1d51959bf569a7419fe8ab9416b338334b4800 (patch)
tree157ac4ebb53494dfe4f6a73b3c2ccc102a30e27e /actionpack
parent5bcd119b8d9bb6d88c949956de1ce13c2673b877 (diff)
downloadrails-3a1d51959bf569a7419fe8ab9416b338334b4800.tar.gz
rails-3a1d51959bf569a7419fe8ab9416b338334b4800.tar.bz2
rails-3a1d51959bf569a7419fe8ab9416b338334b4800.zip
deprecation warning, changelog entry
Diffstat (limited to 'actionpack')
-rw-r--r--actionpack/CHANGELOG.md4
-rw-r--r--actionpack/lib/action_dispatch/middleware/show_exceptions.rb4
2 files changed, 7 insertions, 1 deletions
diff --git a/actionpack/CHANGELOG.md b/actionpack/CHANGELOG.md
index dc52262503..fe422f71d5 100644
--- a/actionpack/CHANGELOG.md
+++ b/actionpack/CHANGELOG.md
@@ -1,5 +1,9 @@
## Rails 3.2.0 (unreleased) ##
+* Refactor ActionDispatch::ShowExceptions. Controller is responsible for choice to show exceptions. *Sergey Nartimov*
+
+ It's possible to override +show_detailed_exceptions?+ in controllers to specify which requests should provide debugging information on errors.
+
* Responders now return 204 No Content for API requests without a response body (as in the new scaffold) *José Valim*
* Added ActionDispatch::RequestId middleware that'll make a unique X-Request-Id header available to the response and enables the ActionDispatch::Request#uuid method. This makes it easy to trace requests from end-to-end in the stack and to identify individual requests in mixed logs like Syslog *DHH*
diff --git a/actionpack/lib/action_dispatch/middleware/show_exceptions.rb b/actionpack/lib/action_dispatch/middleware/show_exceptions.rb
index 569063f4db..52dce4cc81 100644
--- a/actionpack/lib/action_dispatch/middleware/show_exceptions.rb
+++ b/actionpack/lib/action_dispatch/middleware/show_exceptions.rb
@@ -2,6 +2,7 @@ require 'active_support/core_ext/exception'
require 'action_controller/metal/exceptions'
require 'active_support/notifications'
require 'action_dispatch/http/request'
+require 'active_support/deprecation'
module ActionDispatch
# This middleware rescues any exception returned by the application and renders
@@ -38,7 +39,8 @@ module ActionDispatch
"application's log file and/or the web server's log file to find out what " <<
"went wrong.</body></html>"]]
- def initialize(app)
+ def initialize(app, consider_all_requests_local = nil)
+ ActiveSupport::Deprecation.warn "Passing consider_all_requests_local option to ActionDispatch::ShowExceptions middleware no longer works" unless consider_all_requests_local.nil?
@app = app
end