use Travis.config.github.ssl when fetching an oauth access token
This commit is contained in:
parent
1080bee23b
commit
f3a2cc2f40
|
@ -276,7 +276,7 @@ class Travis::Api::App
|
||||||
end
|
end
|
||||||
|
|
||||||
def get_token(endoint, values)
|
def get_token(endoint, values)
|
||||||
response = Faraday.post(endoint, values)
|
response = Faraday.new(ssl: Travis.config.github.ssl).post(endoint, values)
|
||||||
parameters = Addressable::URI.form_unencode(response.body)
|
parameters = Addressable::URI.form_unencode(response.body)
|
||||||
token_info = parameters.assoc("access_token")
|
token_info = parameters.assoc("access_token")
|
||||||
halt 401, 'could not resolve github token' unless token_info
|
halt 401, 'could not resolve github token' unless token_info
|
||||||
|
|
Loading…
Reference in New Issue
Block a user