Sha256: deb1c497535c157846cdac092db3d7d41f0a2b8f76be72577ec3ff61ace705ec
Contents?: true
Size: 490 Bytes
Versions: 29
Compression:
Stored size: 490 Bytes
Contents
module TreasureData module Logger module Agent::Rack class Hook @@before = [] @@after = [] def self.before(&block) @@before << block end def self.after(&block) @@after << block end def initialize(app, options={}) @app = app end def call(env) @@before.each {|m| m.call(env) } result = @app.call(env) @@after.each {|m| m.call(env, result) } result end end end end end
Version data entries
29 entries across 29 versions & 1 rubygems