rails_exception_handler 2.3.1 → 2.3.2
Sign up to get free protection for your applications and to get access to all the features.
- data/Gemfile +3 -3
- data/Gemfile.lock +1 -1
- data/HISTORY +3 -0
- data/VERSION +1 -1
- data/lib/rails_exception_handler.rb +1 -0
- data/lib/rails_exception_handler/catcher.rb +16 -0
- data/rails_exception_handler.gemspec +2 -1
- metadata +3 -2
data/Gemfile
CHANGED
@@ -3,9 +3,9 @@ source "http://rubygems.org"
|
|
3
3
|
group :test, :development do
|
4
4
|
|
5
5
|
#gem "rails", '3.0.20'
|
6
|
-
|
7
|
-
|
8
|
-
|
6
|
+
#gem "rack-test", '0.5.7'
|
7
|
+
#gem 'mongoid'
|
8
|
+
#gem 'bson_ext'
|
9
9
|
|
10
10
|
#gem "rails", '3.2.13'
|
11
11
|
#gem "rack-test", '0.6.2'
|
data/Gemfile.lock
CHANGED
data/HISTORY
CHANGED
data/VERSION
CHANGED
@@ -1 +1 @@
|
|
1
|
-
2.3.
|
1
|
+
2.3.2
|
@@ -0,0 +1,16 @@
|
|
1
|
+
class RailsExceptionHandler
|
2
|
+
|
3
|
+
def self.catch(&block)
|
4
|
+
begin
|
5
|
+
block.call
|
6
|
+
rescue Exception => exception
|
7
|
+
if(configuration.activate?)
|
8
|
+
exception_handler = Handler.new({'REQUEST_METHOD' => "GET", "rack.input" => ""}, exception)
|
9
|
+
exception_handler.handle_exception
|
10
|
+
else
|
11
|
+
raise exception
|
12
|
+
end
|
13
|
+
end
|
14
|
+
end
|
15
|
+
|
16
|
+
end
|
@@ -5,7 +5,7 @@
|
|
5
5
|
|
6
6
|
Gem::Specification.new do |s|
|
7
7
|
s.name = "rails_exception_handler"
|
8
|
-
s.version = "2.3.
|
8
|
+
s.version = "2.3.2"
|
9
9
|
|
10
10
|
s.required_rubygems_version = Gem::Requirement.new(">= 0") if s.respond_to? :required_rubygems_version=
|
11
11
|
s.authors = ["Sharagoz"]
|
@@ -35,6 +35,7 @@ Gem::Specification.new do |s|
|
|
35
35
|
"lib/generators/rails_exception_handler/templates/rails_exception_handler.rb",
|
36
36
|
"lib/patch/show_exceptions.rb",
|
37
37
|
"lib/rails_exception_handler.rb",
|
38
|
+
"lib/rails_exception_handler/catcher.rb",
|
38
39
|
"lib/rails_exception_handler/configuration.rb",
|
39
40
|
"lib/rails_exception_handler/engine.rb",
|
40
41
|
"lib/rails_exception_handler/handler.rb",
|
metadata
CHANGED
@@ -1,7 +1,7 @@
|
|
1
1
|
--- !ruby/object:Gem::Specification
|
2
2
|
name: rails_exception_handler
|
3
3
|
version: !ruby/object:Gem::Version
|
4
|
-
version: 2.3.
|
4
|
+
version: 2.3.2
|
5
5
|
prerelease:
|
6
6
|
platform: ruby
|
7
7
|
authors:
|
@@ -165,6 +165,7 @@ files:
|
|
165
165
|
- lib/generators/rails_exception_handler/templates/rails_exception_handler.rb
|
166
166
|
- lib/patch/show_exceptions.rb
|
167
167
|
- lib/rails_exception_handler.rb
|
168
|
+
- lib/rails_exception_handler/catcher.rb
|
168
169
|
- lib/rails_exception_handler/configuration.rb
|
169
170
|
- lib/rails_exception_handler/engine.rb
|
170
171
|
- lib/rails_exception_handler/handler.rb
|
@@ -201,7 +202,7 @@ required_ruby_version: !ruby/object:Gem::Requirement
|
|
201
202
|
version: '0'
|
202
203
|
segments:
|
203
204
|
- 0
|
204
|
-
hash: -
|
205
|
+
hash: -2232335349036436667
|
205
206
|
required_rubygems_version: !ruby/object:Gem::Requirement
|
206
207
|
none: false
|
207
208
|
requirements:
|