diff --git a/app/models/user_omniauth.rb b/app/models/user_omniauth.rb index d33f26a..aa52685 100644 --- a/app/models/user_omniauth.rb +++ b/app/models/user_omniauth.rb @@ -1,9 +1,19 @@ # frozen_string_literal: true class UserOmniauth < ApplicationRecord + ################ + # Associations # + ################ + belongs_to :user + ############### + # Validations # + ############### + validates :provider, presence: true, uniqueness: { scope: :remote_id } + validates :remote_id, presence: true + validates :email, presence: true end