Skip to content

Commit 3be4ea6

Browse files
committed
Remove faraday dependency
1 parent d103979 commit 3be4ea6

File tree

2 files changed

+2
-4
lines changed

2 files changed

+2
-4
lines changed

lib/omniauth/strategies/oauth2.rb

Lines changed: 2 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -3,7 +3,6 @@
33
require 'securerandom'
44
require 'socket' # for SocketError
55
require 'timeout' # for Timeout::Error
6-
require 'faraday' # for Faraday::Error::TimeoutError and Faraday::Error::ConnectionFailed
76

87
module OmniAuth
98
module Strategies
@@ -77,9 +76,9 @@ def callback_phase # rubocop:disable AbcSize, CyclomaticComplexity, MethodLength
7776
end
7877
rescue ::OAuth2::Error, CallbackError => e
7978
fail!(:invalid_credentials, e)
80-
rescue ::Timeout::Error, ::Errno::ETIMEDOUT, Faraday::Error::TimeoutError => e
79+
rescue ::Timeout::Error, ::Errno::ETIMEDOUT => e
8180
fail!(:timeout, e)
82-
rescue ::SocketError, Faraday::Error::ConnectionFailed => e
81+
rescue ::SocketError => e
8382
fail!(:failed_to_connect, e)
8483
end
8584

omniauth-oauth2.gemspec

Lines changed: 0 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -3,7 +3,6 @@ $LOAD_PATH.unshift(lib) unless $LOAD_PATH.include?(lib)
33
require 'omniauth-oauth2/version'
44

55
Gem::Specification.new do |gem|
6-
gem.add_dependency 'faraday', ['>= 0.8', '< 0.10']
76
gem.add_dependency 'oauth2', '~> 1.0'
87
gem.add_dependency 'omniauth', '~> 1.2'
98

0 commit comments

Comments
 (0)