mirror of
https://github.com/internetee/registry.git
synced 2025-08-06 01:35:10 +02:00
Merge remote-tracking branch 'origin/master' into story/118822101-epp-errors
This commit is contained in:
commit
2f0182b083
5 changed files with 31 additions and 7 deletions
|
@ -478,7 +478,8 @@ class Domain < ActiveRecord::Base
|
|||
def validate_nameserver_ips
|
||||
nameservers.to_a.reject(&:marked_for_destruction?).each do |ns|
|
||||
next unless ns.hostname.end_with?(".#{name}")
|
||||
next if ns.ipv4.present?
|
||||
next if ns.ipv4.present? || ns.ipv6.present?
|
||||
|
||||
errors.add(:nameservers, :invalid) if errors[:nameservers].blank?
|
||||
ns.errors.add(:ipv4, :blank)
|
||||
end
|
||||
|
|
|
@ -32,7 +32,7 @@ class Nameserver < ActiveRecord::Base
|
|||
[:ipv4, :invalid, { value: { obj: 'hostAddr', val: ipv4 } }],
|
||||
[:ipv6, :invalid, { value: { obj: 'hostAddr', val: ipv6 } }]
|
||||
],
|
||||
'2306' => [
|
||||
'2003' => [
|
||||
[:ipv4, :blank]
|
||||
]
|
||||
}
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue