Sha256: bb2be53e1ef9ec9c5b020d51ebd8fa906bd599351c3c643b47b6d94e212573be

Contents?: true

Size: 239 Bytes

Versions: 11

Compression:

Stored size: 239 Bytes

Contents

module BoletoSimples
  module Middleware
    class UserAgent < Faraday::Middleware
      def call(env)
        env[:request_headers]["User-Agent"] = BoletoSimples.configuration.user_agent
        @app.call(env)
      end
    end
  end
end

Version data entries

11 entries across 11 versions & 1 rubygems

Version Path
boletosimples-0.6.0 lib/boletosimples/middlewares/user_agent.rb
boletosimples-0.5.0 lib/boletosimples/middlewares/user_agent.rb
boletosimples-0.4.2 lib/boletosimples/middlewares/user_agent.rb
boletosimples-0.4.1 lib/boletosimples/middlewares/user_agent.rb
boletosimples-0.4.0 lib/boletosimples/middlewares/user_agent.rb
boletosimples-0.3.1 lib/boletosimples/middlewares/user_agent.rb
boletosimples-0.3.0 lib/boletosimples/middlewares/user_agent.rb
boletosimples-0.2.3 lib/boletosimples/middlewares/user_agent.rb
boletosimples-0.2.2 lib/boletosimples/middlewares/user_agent.rb
boletosimples-0.2.0 lib/boletosimples/middlewares/user_agent.rb
boletosimples-0.1.1 lib/boletosimples/middlewares/user_agent.rb