mirror of
https://github.com/LadybirdBrowser/ladybird.git
synced 2024-09-30 00:31:14 +00:00
LibCore: Convert String::format() => String::formatted()
This commit is contained in:
parent
3a891abc37
commit
f4a15c8d42
Notes:
sideshowbarker
2024-07-18 19:15:37 +09:00
Author: https://github.com/awesomekling Commit: https://github.com/SerenityOS/serenity/commit/f4a15c8d428
|
@ -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);
|
||||
}
|
||||
};
|
||||
|
||||
|
|
|
@ -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:
|
||||
|
|
Loading…
Reference in a new issue