Class: Faraday::Connection

Inherits:
Object
  • Object
show all
Defined in:
lib/faraday/digestauth.rb

Instance Method Summary collapse

Instance Method Details

#digest_auth(user, password) ⇒ Object

Public: Adds the digest auth middleware at the top and sets the user and password.

user - A String with the user. password - A String with the password.



89
90
91
# File 'lib/faraday/digestauth.rb', line 89

def digest_auth(user, password)
  self.builder.insert(0, Faraday::Request::DigestAuth, user, password)
end