Sha256: b64f15cd870843d46a0180412601780f587dc8e6a8e8c4d2021584857a7d5064

Contents?: true

Size: 309 Bytes

Versions: 27

Compression:

Stored size: 309 Bytes

Contents

module Grape
  module Middleware
    module Auth
      StrategyInfo = Struct.new(:auth_class, :settings_fetcher) do
        def create(app, options, &block)
          strategy_args = settings_fetcher.call(options)

          auth_class.new(app, *strategy_args, &block)
        end
      end
    end
  end
end

Version data entries

27 entries across 27 versions & 2 rubygems

Version Path
grape-0.15.0 lib/grape/middleware/auth/strategy_info.rb
grape-0.14.0 lib/grape/middleware/auth/strategy_info.rb
grape-0.13.0 lib/grape/middleware/auth/strategy_info.rb
grape-0.12.0 lib/grape/middleware/auth/strategy_info.rb
grape-0.11.0 lib/grape/middleware/auth/strategy_info.rb
grape-0.10.1 lib/grape/middleware/auth/strategy_info.rb
grape-0.10.0 lib/grape/middleware/auth/strategy_info.rb