diff options
| author | Douglas Barbosa Alexandre <dbalexandre@gmail.com> | 2017-04-24 21:21:58 -0300 | 
|---|---|---|
| committer | Douglas Barbosa Alexandre <dbalexandre@gmail.com> | 2017-04-24 21:21:58 -0300 | 
| commit | 30794972f46de4d3af1c3f1843d46f1162660c3e (patch) | |
| tree | a7122fd3589846110eadb11912886f65b4076db3 /lib | |
| parent | 5d106f2597bb009f0e7b8d5ed02b6f2206237e7e (diff) | |
| download | gitlab-ce-30794972f46de4d3af1c3f1843d46f1162660c3e.tar.gz | |
Set timeout options to the Github::Client
Diffstat (limited to 'lib')
| -rw-r--r-- | lib/github/client.rb | 2 | 
1 files changed, 2 insertions, 0 deletions
diff --git a/lib/github/client.rb b/lib/github/client.rb index bf1b2b0a523..e65d908d232 100644 --- a/lib/github/client.rb +++ b/lib/github/client.rb @@ -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  | 
