mirror of
https://github.com/samsonjs/grape_logging.git
synced 2026-03-25 08:55:47 +00:00
Make RequestLogger#initialize signature match Grape 2.4
This commit is contained in:
parent
a20d392807
commit
4ecaf2edaa
2 changed files with 3 additions and 3 deletions
|
|
@ -14,8 +14,8 @@ module GrapeLogging
|
|||
# to use int in parameters
|
||||
attr_accessor :response_status, :response_body
|
||||
|
||||
def initialize(app, options = {})
|
||||
super(app, **options)
|
||||
def initialize(app, **options)
|
||||
super
|
||||
|
||||
@included_loggers = @options[:include] || []
|
||||
@reporter =
|
||||
|
|
|
|||
|
|
@ -5,7 +5,7 @@ describe GrapeLogging::Middleware::RequestLogger do
|
|||
let(:env) { { 'action_dispatch.request_id' => 'request-abc123' } }
|
||||
let(:subject) { request.send(request_method, path, env) }
|
||||
let(:app) { proc { [status, {}, ['response body']] } }
|
||||
let(:stack) { described_class.new app, options }
|
||||
let(:stack) { described_class.new app, **options }
|
||||
let(:request) { Rack::MockRequest.new(stack) }
|
||||
let(:options) { { include: [], logger: logger } }
|
||||
let(:logger) { double('logger') }
|
||||
|
|
|
|||
Loading…
Reference in a new issue