Skip to content

Commit 62e1469

Browse files
YuheiNakasakabyroot
authored andcommitted
[ruby/json] Fix redundant to_str call
ruby/json@61f022dfbd
1 parent 8fe8021 commit 62e1469

File tree

1 file changed

+1
-1
lines changed

1 file changed

+1
-1
lines changed

ext/json/lib/json/common.rb

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -26,7 +26,7 @@ def [](object, opts = {})
2626
elsif object.respond_to?(:to_str)
2727
str = object.to_str
2828
if str.is_a?(String)
29-
return JSON.parse(object.to_str, opts)
29+
return JSON.parse(str, opts)
3030
end
3131
end
3232

0 commit comments

Comments
 (0)