We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
1 parent 771c3ec commit a16becbCopy full SHA for a16becb
lib/restful_error/exceptions_controller.rb
@@ -7,7 +7,7 @@ def self.controller_path = "restful_error"
7
8
def show
9
@exception = request.env["action_dispatch.exception"]
10
- code = request.path_info[1..].to_i
+ code = @exception.try(:http_status) || request.path_info[1..].to_i
11
status = RestfulError.build_status_from_symbol_or_code(code)
12
@status_code = status.code
13
@reason_phrase = status.reason_phrase
0 commit comments