Everywhere: Replace DateTime::to_string() with UnixDateTime::to_string()

Replace LibCore::DateTime::to_string() with
AK::UnixDateTime::to_string().
Remove unncessary #include <LibCore/DateTime.h>.
This commit is contained in:
Tomasz Strejczek 2025-06-19 21:05:42 +02:00 committed by Andrew Kaster
commit 6fb2be96bf
Notes: github-actions[bot] 2025-06-20 00:44:11 +00:00
13 changed files with 25 additions and 30 deletions

View file

@ -7,7 +7,6 @@
#include <AK/NumberFormat.h>
#include <AK/QuickSort.h>
#include <AK/SourceGenerator.h>
#include <LibCore/DateTime.h>
#include <LibCore/Directory.h>
#include <LibCore/Resource.h>
#include <LibCore/System.h>
@ -65,7 +64,7 @@ ErrorOr<String> load_file_directory_page(URL::URL const& url)
contents.appendff("<td><span class=\"{}\"></span></td>", is_directory ? "folder" : "file");
contents.appendff("<td><a href=\"file://{}\">{}</a></td><td>&nbsp;</td>", path, name);
contents.appendff("<td>{:10}</td><td>&nbsp;</td>", is_directory ? "-"_string : human_readable_size(st.st_size));
contents.appendff("<td>{}</td>", Core::DateTime::from_timestamp(st.st_mtime).to_byte_string());
contents.appendff("<td>{}</td>", AK::UnixDateTime::from_seconds_since_epoch(st.st_mtime).to_byte_string());
contents.append("</tr>\n"sv);
}
}