stadtratmonitor/app/models/user.rb

6 lines
146 B
Ruby
Raw Normal View History

class User < ActiveRecord::Base
def self.find_or_create_from_auth_hash(hash)
User.find_or_create_by(email: hash['info']['email'])
end
end