lib/heartland/client/uri.rb in heartland-retail-5.0.0 vs lib/heartland/client/uri.rb in heartland-retail-5.0.1
- old
+ new
@@ -36,10 +36,11 @@
#
# @return [URI]
def subpath(subpath)
uri = dup
uri.path = "#{path}/" unless path.end_with?('/')
- uri.path = uri.path + ::URI.encode(subpath.to_s.gsub(/^\//, ''))
+ escaped_subpath = ::URI::Parser.new.escape(subpath.to_s.gsub(/^\//, ''))
+ uri.path = uri.path + escaped_subpath
uri
end
##
# Merges the given hash of query string parameters and values with the URI's