mirror of
https://github.com/internetee/registry.git
synced 2025-06-12 15:44:45 +02:00
Fix contact deletion if contact *DeleteProhibited
This commit is contained in:
parent
fad739d279
commit
340e1820f2
4 changed files with 10 additions and 2 deletions
|
@ -19,6 +19,11 @@ module Actions
|
|||
return
|
||||
end
|
||||
|
||||
if contact.delete_prohibited?
|
||||
contact.errors.add(:status, :delete_prohibited)
|
||||
return
|
||||
end
|
||||
|
||||
commit
|
||||
end
|
||||
|
||||
|
|
|
@ -83,7 +83,8 @@ class Epp::Contact < Contact
|
|||
[:code, :epp_id_taken]
|
||||
],
|
||||
'2305' => [ # Association exists
|
||||
[:domains, :exist]
|
||||
[:domains, :exist],
|
||||
[:domains, :delete_prohibited],
|
||||
]
|
||||
}
|
||||
end
|
||||
|
|
|
@ -25,6 +25,8 @@ en:
|
|||
email_regex_check_error: Invalid format
|
||||
domains:
|
||||
exist: 'Object association prohibits operation'
|
||||
status:
|
||||
delete_prohibited: Contact delete prohibited by status
|
||||
statuses:
|
||||
not_uniq: 'not uniq'
|
||||
country_code:
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue