Method: Egalite::HTTP.parse_options
- Defined in:
- lib/egalite/http.rb
.parse_options(options) ⇒ Object
31 32 33 34 35 36 37 38 39 |
# File 'lib/egalite/http.rb', line 31 def self.() if [:basic_auth] u = [:basic_auth][0] pw = [:basic_auth][1] b = ["#{u}:#{pw}"].pack("m") [:header] ||= {} [:header]["Authorization"] = "Basic #{b}".chop end end |