not_found_catcher 0.1.0 → 0.1.1

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: 7991ac97bef725470d70a77ad378e7cbf4f24eeb
4
- data.tar.gz: '0051002885918d4274ce36a530edea8dc18e0466'
3
+ metadata.gz: d3fe3735ef2612d8ed88e21966bb9a4a5c6d8139
4
+ data.tar.gz: 50564927e40e1034e0b8f9e11a12390c1813f9ca
5
5
  SHA512:
6
- metadata.gz: 0f9e687d926cbcfcb0895b1f363cc7b501076a552aafe4cf18707e935e39c732874b88ff94f47b4997c7a451093075db508b858f312f2ef4e034a2462a3a1fa5
7
- data.tar.gz: be2aeb383e882a90b850193da0eea12ee5e51e8b70ac7151c17c5c4bd0a709cbcc71ab05dfdc9e91c48697117e5a4d3dcb596776b268ac7c594a8b17f80ff7f2
6
+ metadata.gz: 65513e6047ab9b2ca7d50c0c25d86920d8ab455de998eab12fc74efa05a151c36eb5a7bce28a25e65082211c7c280cde919009215b0df0a53d63669788ecb458
7
+ data.tar.gz: 21629de87a8d906a49b8a627098aa5edef5ad92e48fb38fc04039e15b1b8e407c832349da72e5c1266c097d220910b83b75c8ada38749907141a92fe4d10bac6
data/config/routes.rb CHANGED
@@ -8,6 +8,9 @@ end
8
8
 
9
9
  ##
10
10
  # Appendo una rotta finale per matchare tutto quello sbagliato
11
+
11
12
  Rails.application.routes.append do
12
- match '*path', controller: 'not_found_catcher/exceptions', action: :show, via: [:get, :post, :put, :delete]
13
+ if NotFoundCatcher.enabled
14
+ match '*path', controller: 'not_found_catcher/exceptions', action: :show, via: [:get, :post, :put, :delete]
15
+ end
13
16
  end
@@ -10,7 +10,9 @@ module NotFoundCatcher
10
10
  # end
11
11
 
12
12
  initializer 'not_found_catcher.set_error_catcher_middleware' do |app|
13
- app.config.middleware.use NotFoundCatcher::Middleware
13
+ if NotFoundCatcher.enabled
14
+ app.config.middleware.use NotFoundCatcher::Middleware
15
+ end
14
16
  end
15
17
 
16
18
  end
@@ -1,3 +1,3 @@
1
1
  module NotFoundCatcher
2
- VERSION = '0.1.0'
2
+ VERSION = '0.1.1'
3
3
  end
metadata CHANGED
@@ -1,14 +1,14 @@
1
1
  --- !ruby/object:Gem::Specification
2
2
  name: not_found_catcher
3
3
  version: !ruby/object:Gem::Version
4
- version: 0.1.0
4
+ version: 0.1.1
5
5
  platform: ruby
6
6
  authors:
7
7
  - Marino Bonetti
8
8
  autorequire:
9
9
  bindir: bin
10
10
  cert_chain: []
11
- date: 2019-03-04 00:00:00.000000000 Z
11
+ date: 2019-03-05 00:00:00.000000000 Z
12
12
  dependencies:
13
13
  - !ruby/object:Gem::Dependency
14
14
  name: rails