stadtratmonitor/app/models/user.rb

8 lines
177 B
Ruby
Raw Normal View History

2020-03-09 12:13:27 +01:00
# frozen_string_literal: true
class User < ActiveRecord::Base
def self.find_or_create_from_auth_hash(hash)
User.find_or_create_by(email: hash['info']['email'])
end
end