mirror of
https://github.com/RGBCube/serenity
synced 2025-07-25 21:47:46 +00:00
LibCore: Support (and use) DateTime string formatting of the form %Z
This formats the time zone name. This is now used in the default format string because DateTime is meant to represent local time; it only makes sense to include the time zone by default now that we support non-UTC.
This commit is contained in:
parent
9605be19bb
commit
29c8ec5eb6
2 changed files with 4 additions and 1 deletions
|
@ -246,6 +246,9 @@ String DateTime::to_string(const String& format) const
|
|||
|
||||
format_time_zone_offset(true);
|
||||
break;
|
||||
case 'Z':
|
||||
builder.append(tzname[0]);
|
||||
break;
|
||||
case '%':
|
||||
builder.append('%');
|
||||
break;
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue