lib/httpx/plugins/oauth.rb in httpx-0.24.7 vs lib/httpx/plugins/oauth.rb in httpx-1.0.0
- old
+ new
@@ -6,11 +6,11 @@
# https://gitlab.com/os85/httpx/wikis/OAuth
#
module OAuth
class << self
def load_dependencies(_klass)
- require_relative "authentication/basic"
+ require_relative "auth/basic"
end
end
SUPPORTED_GRANT_TYPES = %w[client_credentials refresh_token].freeze
SUPPORTED_AUTH_METHODS = %w[client_secret_basic client_secret_post].freeze
@@ -104,10 +104,10 @@
end
end
end
module InstanceMethods
- def oauth_authentication(**args)
+ def oauth_auth(**args)
with(oauth_session: OAuthSession.new(**args))
end
def with_access_token
oauth_session = @options.oauth_session