lib/relaton/element_finder.rb in relaton-cli-1.5.0 vs lib/relaton/element_finder.rb in relaton-cli-1.6.pre1

- old
+ new

@@ -13,13 +13,13 @@ def find_xpath(xpath, element = nil) element&.xpath(apply_namespace(xpath)) end def apply_namespace(xpath) - xpath. - gsub(%r{/([a-zA-Z])}, "/xmlns:\\1"). - gsub(%r{::([a-zA-Z])}, "::xmlns:\\1"). - gsub(%r{\[([a-zA-Z][a-z0-9A-Z@/]* ?=)}, "[xmlns:\\1"). - gsub(%r{\[([a-zA-Z][a-z0-9A-Z@/]*\])}, "[xmlns:\\1") + xpath + .gsub(%r{/([a-zA-Z])}, "/xmlns:\\1") + .gsub(%r{::([a-zA-Z])}, "::xmlns:\\1") + .gsub(%r{\[([a-zA-Z][a-z0-9A-Z@/]* ?=)}, "[xmlns:\\1") + .gsub(%r{\[([a-zA-Z][a-z0-9A-Z@/]*\])}, "[xmlns:\\1") end end end