Welcome to mirror list, hosted at ThFree Co, Russian Federation.

banned_user.rb « users « models « app - gitlab.com/gitlab-org/gitlab-foss.git - Unnamed repository; edit this file 'description' to name the repository.
summaryrefslogtreecommitdiff
blob: 466fc71f83a611975ffb1212f110b773a74cfebc (plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
# frozen_string_literal: true

module Users
  class BannedUser < ApplicationRecord
    self.primary_key = :user_id

    belongs_to :user

    validates :user, presence: true
    validates :user_id, uniqueness: { message: N_("banned user already exists") }
  end
end

Users::BannedUser.prepend_mod_with('Users::BannedUser')