diff --git a/lib/ipaddr.rb b/lib/ipaddr.rb index b40d5c0359..dc33fffcb5 100644 --- a/lib/ipaddr.rb +++ b/lib/ipaddr.rb @@ -246,7 +246,7 @@ class IPAddr # Returns a string containing the IP address representation in # cidr notation def cidr - format("%s/%s", to_s, prefix) + "#{to_s}/#{prefix}" end # Returns a network byte ordered string form of the IP address.