diff options
-rw-r--r-- | Userland/Libraries/LibJS/Runtime/Date.h | 3 |
1 files changed, 2 insertions, 1 deletions
diff --git a/Userland/Libraries/LibJS/Runtime/Date.h b/Userland/Libraries/LibJS/Runtime/Date.h index 1b91d022ae..33a6502ae9 100644 --- a/Userland/Libraries/LibJS/Runtime/Date.h +++ b/Userland/Libraries/LibJS/Runtime/Date.h @@ -6,6 +6,7 @@ #pragma once +#include <AK/Math.h> #include <LibCore/DateTime.h> #include <LibJS/Runtime/Object.h> @@ -78,7 +79,7 @@ public: double date_value() const { return m_is_invalid - ? NAN + ? AK::NaN<double> : static_cast<double>(m_datetime.timestamp() * 1000 + m_milliseconds); } |