LibCore: Convert String::format() => String::formatted()

This commit is contained in:
Andreas Kling 2021-04-21 23:36:31 +02:00
parent 3a891abc37
commit f4a15c8d42
Notes: sideshowbarker 2024-07-18 19:15:37 +09:00
2 changed files with 3 additions and 3 deletions

View file

@ -53,8 +53,8 @@ public:
String name_for_display() const
{
if (long_name)
return String::format("--%s", long_name);
return String::format("-%c", short_name);
return String::formatted("--{}", long_name);
return String::formatted("-{:c}", short_name);
}
};

View file

@ -74,7 +74,7 @@ public:
{
switch (m_type) {
case Type::IPv4:
return String::format("%s:%d", m_ipv4_address.to_string().characters(), m_port);
return String::formatted("{}:{}", m_ipv4_address, m_port);
case Type::Local:
return m_local_address;
default: