Sha256: 8fcc5e0f8f0ac60983824935a71470827d44e15feb5598d48c386c3840ff6620

Contents?: true

Size: 387 Bytes

Versions: 5

Compression:

Stored size: 387 Bytes

Contents

# frozen_string_literal: true

require 'rack/simple_user_agent/version'
require 'rack/simple_user_agent/detectors'
require 'rack/simple_user_agent/railtie' if defined?(Rails)

module Rack
  class SimpleUserAgent
    def initialize(app)
      @app = app
    end

    def call(env)
      @app.call(env)
    end
  end

  class Request
    include Rack::SimpleUserAgent::Detectors
  end
end

Version data entries

5 entries across 5 versions & 1 rubygems

Version Path
rack-simple_user_agent-1.1.1 lib/rack/simple_user_agent.rb
rack-simple_user_agent-1.1.0 lib/rack/simple_user_agent.rb
rack-simple_user_agent-1.0.0 lib/rack/simple_user_agent.rb
rack-simple_user_agent-0.6.0 lib/rack/simple_user_agent.rb
rack-simple_user_agent-0.5.0 lib/rack/simple_user_agent.rb