diff --git a/lib/ruby_http_client.rb b/lib/ruby_http_client.rb index 4d0aafd..f2bbdd6 100644 --- a/lib/ruby_http_client.rb +++ b/lib/ruby_http_client.rb @@ -212,8 +212,7 @@ def add_ssl(http) # - Client object # def _(name = nil) - url_path = name ? @url_path.push(name) : @url_path - @url_path = [] + url_path = name ? @url_path + [name] : @url_path Client.new(host: @host, request_headers: @request_headers, version: @version, url_path: url_path, http_options: @http_options)