about summary refs log tree commit diff
path: root/app/models/domain_block.rb
blob: 8f9eb11826fc2429695520d19cdc22f12c68d115 (plain) (blame)
1
2
3
4
5
6
7
class DomainBlock < ApplicationRecord
  validates :domain, presence: true, uniqueness: true

  def self.blocked?(domain)
    where(domain: domain).exists?
  end
end