Method: Hub::GitHubAPI::HttpMethods#apply_authentication
- Defined in:
- lib/hub/github_api.rb
#apply_authentication(req, url) ⇒ Object
183 184 185 186 187 |
# File 'lib/hub/github_api.rb', line 183 def apply_authentication req, url user = url.user || config.username(url.host) pass = config.password(url.host, user) req.basic_auth user, pass end |