Merge branch 'master' into registry-693

# Conflicts:
#	app/api/repp/domain_transfers_v1.rb
This commit is contained in:
Artur Beljajev 2018-02-24 06:24:49 +02:00
commit 1fad07963f
41 changed files with 524 additions and 285 deletions

View file

@ -142,6 +142,13 @@ class Epp::DomainsController < EppController
authorize! :transfer, @domain, @password
action = params[:parsed_frame].css('transfer').first[:op]
if @domain.non_transferable?
throw :epp_error, {
code: '2304',
msg: I18n.t(:object_status_prohibits_operation)
}
end
@domain_transfer = @domain.transfer(params[:parsed_frame], action, current_user)
if @domain_transfer

View file

@ -6,6 +6,8 @@ class Epp::PollsController < EppController
ack_poll if params[:parsed_frame].css('poll').first['op'] == 'ack'
end
private
def req_poll
@message = current_user.queued_messages.last
@ -49,8 +51,6 @@ class Epp::PollsController < EppController
render_epp_response 'epp/poll/poll_ack'
end
private
def validate_poll
requires_attribute 'poll', 'op', values: %(ack req), allow_blank: true
end

View file

@ -335,7 +335,6 @@ class EppController < ApplicationController
# rubocop: disable Metrics/CyclomaticComplexity
# rubocop: disable Metrics/PerceivedComplexity
def write_to_epp_log
# return nil if EPP_LOG_ENABLED
request_command = params[:command] || params[:action] # error receives :command, other methods receive :action
frame = params[:raw_frame] || params[:frame]