mirror of
https://github.com/internetee/registry.git
synced 2025-08-04 00:42:04 +02:00
Require legalDocument on domain create
This commit is contained in:
parent
4aaef3f80b
commit
56c923c988
5 changed files with 57 additions and 10 deletions
|
@ -67,11 +67,10 @@ module Epp::Common
|
|||
def epp_request_valid?(*selectors)
|
||||
selectors.each do |selector|
|
||||
el = parsed_frame.css(selector).first
|
||||
next unless el
|
||||
epp_errors << {
|
||||
code: '2003',
|
||||
msg: I18n.t('errors.messages.required_parameter_missing', key: el.name)
|
||||
} unless el.text.present?
|
||||
msg: I18n.t('errors.messages.required_parameter_missing', key: el.try(:name) || selector)
|
||||
} if el.nil? || el.text.blank?
|
||||
end
|
||||
|
||||
epp_errors.empty?
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue