[ruby/ipaddr] Use string interpolation instead of format()
https://github.com/ruby/ipaddr/commit/1f41cd7320
This commit is contained in:
parent
7be9a333ca
commit
bfc586b2be
@ -239,8 +239,8 @@ class IPAddr
|
|||||||
end
|
end
|
||||||
|
|
||||||
# Returns a json string containing the IP address representation.
|
# Returns a json string containing the IP address representation.
|
||||||
def to_json(*)
|
def to_json(*a)
|
||||||
format("\"%s\"", as_json)
|
%Q{"#{as_json(*a)}"}
|
||||||
end
|
end
|
||||||
|
|
||||||
# Returns a string containing the IP address representation in
|
# Returns a string containing the IP address representation in
|
||||||
|
Loading…
x
Reference in New Issue
Block a user