Validate not_found too against schema #2752

This commit is contained in:
Martin Lensment 2015-07-24 16:38:14 +03:00
parent 626fa6d25d
commit c38680a3b1
3 changed files with 3 additions and 3 deletions

View file

@ -13,7 +13,7 @@ class EppConstraint
request.params[:nokogiri_frame] ||= Nokogiri::XML(request.params[:raw_frame])
request.params[:parsed_frame] ||= request.params[:nokogiri_frame].dup.remove_namespaces!
unless [:keyrelay, :poll, :session].include?(@type)
unless [:keyrelay, :poll, :session, :not_found].include?(@type)
element = "//#{@type}:#{request.params[:action]}"
return false if request.params[:nokogiri_frame].xpath("#{element}", OBJECT_TYPES[@type]).none?
# TODO: Support multiple schemas