Sha256: add5f1e442418bf27ab587b8c775e687c3d9367cb94206d4357feb168a50b224

Contents?: true

Size: 290 Bytes

Versions: 18

Compression:

Stored size: 290 Bytes

Contents

# encoding: utf-8

require 'faraday'

module Nimbu
  class Request::UserAgent < Faraday::Middleware
    include Nimbu::Utils::Constants

    def call(env)
      env[:request_headers].merge!(USER_AGENT => Nimbu.user_agent)

      @app.call env
    end

  end # Request::UserAgent
end # Nimbu

Version data entries

18 entries across 18 versions & 1 rubygems

Version Path
nimbu-api-0.5.0 lib/nimbu-api/request/user_agent.rb
nimbu-api-0.4.4 lib/nimbu-api/request/user_agent.rb
nimbu-api-0.4.3 lib/nimbu-api/request/user_agent.rb
nimbu-api-0.4.2 lib/nimbu-api/request/user_agent.rb
nimbu-api-0.4.1 lib/nimbu-api/request/user_agent.rb
nimbu-api-0.4.0 lib/nimbu-api/request/user_agent.rb
nimbu-api-0.3.0 lib/nimbu-api/request/user_agent.rb
nimbu-api-0.2.1 lib/nimbu-api/request/user_agent.rb
nimbu-api-0.2 lib/nimbu-api/request/user_agent.rb
nimbu-api-0.2.beta.3 lib/nimbu-api/request/user_agent.rb
nimbu-api-0.2.beta.2 lib/nimbu-api/request/user_agent.rb
nimbu-api-0.2.beta.1 lib/nimbu-api/request/user_agent.rb
nimbu-api-0.2.beta lib/nimbu-api/request/user_agent.rb
nimbu-api-0.1.5 lib/nimbu-api/request/user_agent.rb
nimbu-api-0.1.4 lib/nimbu-api/request/user_agent.rb
nimbu-api-0.1.3 lib/nimbu-api/request/user_agent.rb
nimbu-api-0.1.1 lib/nimbu-api/request/user_agent.rb
nimbu-api-0.1 lib/nimbu-api/request/user_agent.rb