2
0

Add EmailDomainBlock.parents scope (#31968)

This commit is contained in:
Matt Jankowski
2024-11-07 08:46:20 -05:00
committed by GitHub
parent 6ae1fcd059
commit 697947116e
3 changed files with 6 additions and 4 deletions

View File

@@ -28,6 +28,8 @@ class EmailDomainBlock < ApplicationRecord
validates :domain, presence: true, uniqueness: true, domain: true
scope :parents, -> { where(parent_id: nil) }
# Used for adding multiple blocks at once
attr_accessor :other_domains