diff options
author | Eugen Rochko <eugen@zeonfederated.com> | 2019-08-08 23:04:19 +0200 |
---|---|---|
committer | GitHub <noreply@github.com> | 2019-08-08 23:04:19 +0200 |
commit | 7a1f8a58df7edeb4f1d03c9dd3c25d5370d858a6 (patch) | |
tree | cc52064354f522e63a70494346655202b3d2ebf9 /app/models/domain_block.rb | |
parent | 699db454c370247684243d7497f6ebacefbb2a57 (diff) |
Fix crash when saving invalid domain name (#11528)
Fix #7629
Diffstat (limited to 'app/models/domain_block.rb')
-rw-r--r-- | app/models/domain_block.rb | 2 |
1 files changed, 1 insertions, 1 deletions
diff --git a/app/models/domain_block.rb b/app/models/domain_block.rb index 3f5b9f23e..37b8d98c6 100644 --- a/app/models/domain_block.rb +++ b/app/models/domain_block.rb @@ -19,7 +19,7 @@ class DomainBlock < ApplicationRecord enum severity: [:silence, :suspend, :noop] - validates :domain, presence: true, uniqueness: true + validates :domain, presence: true, uniqueness: true, domain: true has_many :accounts, foreign_key: :domain, primary_key: :domain delegate :count, to: :accounts, prefix: true |