Set timeout options to the Github::Client
This commit is contained in:
parent
5d106f2597
commit
30794972f4
1 changed files with 2 additions and 0 deletions
|
@ -4,6 +4,8 @@ module Github
|
|||
|
||||
def initialize(options)
|
||||
@connection = Faraday.new(url: options.fetch(:url)) do |faraday|
|
||||
faraday.options.open_timeout = options.fetch(:timeout, 60)
|
||||
faraday.options.timeout = options.fetch(:timeout, 60)
|
||||
faraday.authorization 'token', options.fetch(:token)
|
||||
faraday.adapter :net_http
|
||||
end
|
||||
|
|
Loading…
Reference in a new issue