class ClubMembership < ApplicationRecord
  ROLES = %w[owner].freeze

  belongs_to :user
  belongs_to :club

  validates :role, inclusion: { in: ROLES }
  validates :user_id, uniqueness: { scope: :club_id }
end
