Reject registrant change if serverRegistrantUpdateProhibited

This commit is contained in:
Karl Erik Õunapuu 2021-02-11 11:43:38 +02:00
parent aedfeac459
commit 9d57f347cb
No known key found for this signature in database
GPG key ID: C9DD647298A34764

View file

@ -60,7 +60,12 @@ module Actions
return if domain.registrant == new_registrant
@changes_registrant = true if domain.registrant.ident != new_registrant.ident
domain.registrant = new_registrant
if @changes_registrant && domain.registrant_change_prohibited?
domain.add_epp_error(2304, "status", DomainStatus::SERVER_REGISTRANT_CHANGE_PROHIBITED,
I18n.t(:object_status_prohibits_operation))
else
domain.registrant = new_registrant
end
end
def assign_nameserver_modifications