mirror of
https://github.com/internetee/registry.git
synced 2025-07-22 18:56:05 +02:00
Value returning with error message
This commit is contained in:
parent
3fc3bfc1c4
commit
e4ac417bde
5 changed files with 28 additions and 3 deletions
|
@ -33,7 +33,13 @@ class Domain < ActiveRecord::Base
|
|||
v.each do |x|
|
||||
contact = Contact.find_by(code: x[:contact])
|
||||
attach_contact(k, contact) and next if contact
|
||||
errors.add(:domain_contacts, I18n.t('errors.messages.epp_contact_not_found'))
|
||||
|
||||
# Detailed error message with value to display in EPP response
|
||||
errors.add(:domain_contacts, {
|
||||
obj: 'contact',
|
||||
val: x[:contact],
|
||||
msg: I18n.t('errors.messages.epp_contact_not_found')
|
||||
})
|
||||
end
|
||||
end
|
||||
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue