Remove manual rescues from transfer code #2588

This commit is contained in:
Martin Lensment 2015-07-21 14:43:42 +03:00
parent 812381056c
commit 91da0d30f0
3 changed files with 52 additions and 64 deletions

View file

@ -130,10 +130,14 @@ class Epp::DomainsController < EppController
@domain_transfer = @domain.transfer(params[:parsed_frame], action, current_user)
if @domain.errors.empty? && @domain_transfer
if @domain_transfer
render_epp_response '/epp/domains/transfer'
else
handle_errors(@domain)
epp_errors << {
code: '2303',
msg: I18n.t('no_transfers_found')
}
handle_errors
end
end