class OmniAuth::Strategies::Patreon
Constants
- DEFAULT_SCOPE
¶ ↑
OAuth client settings
¶ ↑
Public Instance Methods
callback_url()
click to toggle source
# File lib/j1_app/omniauth/strategies/patreon.rb, line 43 def callback_url options[:redirect_uri] || full_host + script_name + callback_path end
raw_info()
click to toggle source
# File lib/j1_app/omniauth/strategies/patreon.rb, line 91 def raw_info @raw_info ||= begin response = client.request( :get, 'https://api.patreon.com/oauth2/api/current_user', headers: { 'Authorization' => "Bearer #{access_token.token}" }, parse: :json ) response.parsed end end
Private Instance Methods
get_scope(params)
click to toggle source
prune!(hash)
click to toggle source
# File lib/j1_app/omniauth/strategies/patreon.rb, line 116 def prune!(hash) hash.delete_if do |_, value| prune!(value) if value.is_a?(Hash) value.nil? || (value.respond_to?(:empty?) && value.empty?) end end
skip_extra?()
click to toggle source
# File lib/j1_app/omniauth/strategies/patreon.rb, line 123 def skip_extra? !!options[:skip_extra] end