Replace SERVER_DELETE_PROHIBITED with PENDING_UPDATE on EPP domain:update

#512
This commit is contained in:
Artur Beljajev 2017-05-31 19:48:16 +03:00
parent 48ae54d507
commit 8455f69dbc
2 changed files with 47 additions and 0 deletions

View file

@ -135,6 +135,16 @@ class EppController < ApplicationController
@errors += obj.errors[:epp_errors]
end
if params[:parsed_frame].at_css('update')
@errors.each_with_index do |errors, index|
if errors[:code] == '2304' &&
errors[:value][:val] == DomainStatus::SERVER_DELETE_PROHIBITED &&
errors[:value][:obj] == 'status'
@errors[index][:value][:val] = DomainStatus::PENDING_UPDATE
end
end
end
# for debugging
if @errors.blank?
@errors << {