mirror of
https://github.com/RGBCube/serenity
synced 2025-07-27 11:17:35 +00:00
LibJS: Use AK::abs
in TimeZone
This fixes a `-Wabsolute-value` warning emitted because of our use of `abs()` on arguments of type `long long`.
This commit is contained in:
parent
6821cd45ed
commit
cd55b817cf
1 changed files with 1 additions and 1 deletions
|
@ -210,7 +210,7 @@ String format_time_zone_offset_string(double offset_nanoseconds)
|
|||
builder.append('-');
|
||||
|
||||
// 3. Let nanoseconds be abs(offsetNanoseconds) modulo 10^9.
|
||||
auto nanoseconds = abs(offset) % 1000000000;
|
||||
auto nanoseconds = AK::abs(offset) % 1000000000;
|
||||
|
||||
// 4. Let seconds be floor(offsetNanoseconds / 10^9) modulo 60.
|
||||
auto seconds = (offset / 1000000000) % 60;
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue