Class: OdaniaOmniauthAuthentication::UserAuthentication

Inherits:
ActiveRecord::Base
  • Object
show all
Defined in:
app/models/odania_omniauth_authentication/user_authentication.rb

Class Method Summary collapse

Class Method Details

.create_with_omniauth(auth) ⇒ Object



9
10
11
# File 'app/models/odania_omniauth_authentication/user_authentication.rb', line 9

def self.create_with_omniauth(auth)
	create(provider: auth['provider'], uid: auth['uid'])
end

.find_with_omniauth(auth) ⇒ Object



5
6
7
# File 'app/models/odania_omniauth_authentication/user_authentication.rb', line 5

def self.find_with_omniauth(auth)
	find_by provider: auth['provider'], uid: auth['uid']
end