class Authentication < ActiveRecord::Base belongs_to :person validates :uid, presence: true, uniqueness: { scope: :provider } end