openstax_rescue_from 1.7.1 → 1.7.2
Sign up to get free protection for your applications and to get access to all the features.
checksums.yaml
CHANGED
@@ -1,7 +1,7 @@
|
|
1
1
|
---
|
2
2
|
SHA1:
|
3
|
-
metadata.gz:
|
4
|
-
data.tar.gz:
|
3
|
+
metadata.gz: 3edb483119c3d1c6befcbfa1840abdc13b3260a2
|
4
|
+
data.tar.gz: 7f02796585c56c84c340674906387d29cc4ac552
|
5
5
|
SHA512:
|
6
|
-
metadata.gz:
|
7
|
-
data.tar.gz:
|
6
|
+
metadata.gz: 4804e637da89b5ddce6c8c2566090edf8bbad5853d2ffce87366ad2b7e6fcb962f59034cbbee85b91a8e07eb46346f57481a52818af285b6b448108576f2dc79
|
7
|
+
data.tar.gz: dc42bc4cca39691e65cf52a2a44df8905f838350b80d2915e0a43961934b47cdb1b742d4e88ffd57e5d0d018b77a6408ef9da2d3a94a8134b47f2bb235d6d3fb
|
data/lib/openstax/rescue_from.rb
CHANGED
@@ -96,7 +96,7 @@ module OpenStax
|
|
96
96
|
def friendly_status_messages
|
97
97
|
@@friendly_status_messages ||= {
|
98
98
|
internal_server_error: default_friendly_message,
|
99
|
-
:
|
99
|
+
not_found: 'We could not find the requested information.',
|
100
100
|
bad_request: 'The request was unrecognized.',
|
101
101
|
forbidden: 'You are not allowed to do that.',
|
102
102
|
unprocessable_entity: 'Your browser asked for something that we cannot do.'
|
@@ -125,7 +125,7 @@ module OpenStax
|
|
125
125
|
env: listener.request.env,
|
126
126
|
data: {
|
127
127
|
error_id: proxy.error_id,
|
128
|
-
:
|
128
|
+
class: proxy.name,
|
129
129
|
message: proxy.message,
|
130
130
|
first_line_of_backtrace: proxy.first_backtrace_line,
|
131
131
|
cause: proxy.cause,
|
@@ -44,6 +44,10 @@ module OpenStax
|
|
44
44
|
RescueFrom.register_exception(ActionController::UnknownHttpMethod,
|
45
45
|
notify: false,
|
46
46
|
status: :bad_request)
|
47
|
+
|
48
|
+
RescueFrom.register_exception(ActionController::ParameterMissing,
|
49
|
+
notify: false,
|
50
|
+
status: :bad_request)
|
47
51
|
end
|
48
52
|
end
|
49
53
|
end
|
metadata
CHANGED
@@ -1,7 +1,7 @@
|
|
1
1
|
--- !ruby/object:Gem::Specification
|
2
2
|
name: openstax_rescue_from
|
3
3
|
version: !ruby/object:Gem::Version
|
4
|
-
version: 1.7.
|
4
|
+
version: 1.7.2
|
5
5
|
platform: ruby
|
6
6
|
authors:
|
7
7
|
- JP Slavinsky
|
@@ -9,7 +9,7 @@ authors:
|
|
9
9
|
autorequire:
|
10
10
|
bindir: exe
|
11
11
|
cert_chain: []
|
12
|
-
date:
|
12
|
+
date: 2017-01-04 00:00:00.000000000 Z
|
13
13
|
dependencies:
|
14
14
|
- !ruby/object:Gem::Dependency
|
15
15
|
name: rails
|