hickory 0.1.2 → 0.1.3

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
  SHA256:
3
- metadata.gz: 9d315687d17e63b704dc7748ffad0ca866d5d224c42b2469003faff0061881af
4
- data.tar.gz: 63fd0fb477d88a8b853819daa412b4c6440692f34b2de7174d2e80867144d840
3
+ metadata.gz: 95526be9d2c6c2cf393cd547e944477252e4ca527c0d0afcbdfd221f70e32dbe
4
+ data.tar.gz: 2e2a00ff43e19de1903a1013902a323427b6ae7af1e79f268d84d24977e3bf8f
5
5
  SHA512:
6
- metadata.gz: d025b8a858179df3aa938580e1cb9b07daabc7346b029a821f8fae183a4ec093660cf28b688a692c91616c811a97dbda99cba5cfde2045be196781cf8f96951b
7
- data.tar.gz: 687f88ddf0731a3974bfc2592e4ff802fca7415eab8f48167e578b829e98f5bff9b2e73938f145146d4ac0bd812a54a6ecab77b5c5668da7fcb389699b73b891
6
+ metadata.gz: 3b6de3ba2d0aadda8ac2442ce827093c84b43208c6e1db35d6930a38aaea0a789ea3fe057b1c26af3028b8384ae6c58499f9d961f6ae4b3c34eb7681dc5cd2ba
7
+ data.tar.gz: 30f1055d3259ce95db4fee0fe12cea4151ba62279955d1fc2cd93353b6935e85079b6bca7ce54c05c81e3719fecf8e086d8742b8a0ff5df5529e3735b8a49aa9
@@ -0,0 +1,20 @@
1
+ require 'rails/rack/logger'
2
+
3
+ module Rails
4
+ module Rack
5
+ # Overwrites defaults of Rails::Rack::Logger that cause
6
+ # unnecessary logging.
7
+ # This effectively removes the log lines from the log
8
+ # that say:
9
+ # Started GET / for 192.168.2.1...
10
+ class Logger
11
+ # Overwrites Rails 3.2 code that logs new requests
12
+ def call_app(*args)
13
+ env = args.last
14
+ @app.call(env)
15
+ ensure
16
+ ActiveSupport::LogSubscriber.flush_all!
17
+ end
18
+ end
19
+ end
20
+ end
data/lib/hickory/rails.rb CHANGED
@@ -1,6 +1,7 @@
1
1
  require 'active_support/log_subscriber'
2
2
  require 'active_support/core_ext/module/attribute_accessors'
3
3
 
4
+ require 'hickory/ext/rails/rack/logger'
4
5
  require 'hickory/rails/railtie'
5
6
  require 'hickory/log_subscribers/action_controller'
6
7
  require 'hickory/log_subscribers/action_mailer'
@@ -1,3 +1,3 @@
1
1
  module Hickory
2
- VERSION = '0.1.2'
2
+ VERSION = '0.1.3'
3
3
  end
metadata CHANGED
@@ -1,7 +1,7 @@
1
1
  --- !ruby/object:Gem::Specification
2
2
  name: hickory
3
3
  version: !ruby/object:Gem::Version
4
- version: 0.1.2
4
+ version: 0.1.3
5
5
  platform: ruby
6
6
  authors:
7
7
  - blahed
@@ -112,6 +112,7 @@ files:
112
112
  - bin/setup
113
113
  - hickory.gemspec
114
114
  - lib/hickory.rb
115
+ - lib/hickory/ext/rails/rack/logger.rb
115
116
  - lib/hickory/formatters/json.rb
116
117
  - lib/hickory/formatters/simple.rb
117
118
  - lib/hickory/log_subscribers/action_controller.rb