mirror of
https://github.com/internetee/registry.git
synced 2025-06-08 05:34:46 +02:00
parent
125bb4bb4a
commit
263cb2e123
3 changed files with 19 additions and 1 deletions
|
@ -23,6 +23,13 @@ module Repp
|
|||
:bad_request)
|
||||
end
|
||||
|
||||
if new_contact.invalid?
|
||||
error!({ error: { type: 'invalid_request_error',
|
||||
param: 'new_contact_id',
|
||||
message: 'New contact must be valid' } },
|
||||
:bad_request)
|
||||
end
|
||||
|
||||
if current_contact == new_contact
|
||||
error!({ error: { type: 'invalid_request_error',
|
||||
message: 'New contact ID must be different from current' \
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue