mirror of
https://github.com/RGBCube/serenity
synced 2025-05-31 12:48:10 +00:00
LibJS: Change balance_duration() nanoseconds from a JS to Crypto BigInt
Similar to the preceding commit.
This commit is contained in:
parent
48856498f0
commit
360c65e92b
12 changed files with 28 additions and 35 deletions
|
@ -443,7 +443,7 @@ ThrowCompletionOr<String> Console::value_vector_to_string(Vector<Value>& values)
|
|||
ThrowCompletionOr<String> Console::format_time_since(Core::ElapsedTimer timer)
|
||||
{
|
||||
auto elapsed_ms = timer.elapsed_time().to_milliseconds();
|
||||
auto duration = TRY(Temporal::balance_duration(global_object(), 0, 0, 0, 0, elapsed_ms, 0, *js_bigint(vm(), "0"_sbigint), "year"));
|
||||
auto duration = TRY(Temporal::balance_duration(global_object(), 0, 0, 0, 0, elapsed_ms, 0, "0"_sbigint, "year"));
|
||||
|
||||
auto append = [&](StringBuilder& builder, auto format, auto... number) {
|
||||
if (!builder.is_empty())
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue