Merge branch 'master' of github.com:internetee/registry

This commit is contained in:
Martin Lensment 2014-08-27 14:05:23 +03:00
commit f87a7fa912
2 changed files with 4 additions and 4 deletions

View file

@ -61,7 +61,7 @@ module Epp::Common
epp_errors.empty?
end
def xml_nested_attrs_present?(array_ph, attributes )
def xml_attrs_array_present?(array_ph, attributes )
[array_ph].flatten.each do |ph|
attributes.each do |x|
epp_errors << {code: '2003', msg: I18n.t('errors.messages.required_parameter_missing', key: x.last)} unless has_attribute(ph, x)

View file

@ -53,7 +53,7 @@ module Epp
%w(postalInfo)])
return epp_errors.empty? unless @ph['postalInfo'].is_a?(Hash) || @ph['postalInfo'].is_a?(Array)
xml_nested_attrs_present?(@ph['postalInfo'], [%w(name),
xml_attrs_array_present?(@ph['postalInfo'], [%w(name),
%w(addr city),
%w(addr cc)])
end