Skip to content

Commit

Permalink
call .to_s on passed body
Browse files Browse the repository at this point in the history
for the clients which wrap the request body
  • Loading branch information
HoneyryderChuck committed Oct 31, 2024
1 parent 9ff63ac commit d8c4821
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion lib/webmock/util/query_mapper.rb
Original file line number Diff line number Diff line change
Expand Up @@ -41,7 +41,7 @@ class << self
# #=> [['one', 'two'], ['one', 'three']]
def query_to_values(query, options={})
return nil if query.nil?
query = query.dup.force_encoding('utf-8') if query.respond_to?(:force_encoding)
query = query.to_s.dup.force_encoding('utf-8') if query.respond_to?(:force_encoding)

options[:notation] ||= :subscript

Expand Down

0 comments on commit d8c4821

Please sign in to comment.