mirror of
https://github.com/LadybirdBrowser/ladybird
synced 2026-04-30 19:47:17 +02:00
LibJS: Remove #if !defined(KERNEL)
AK::JsonValue::{is,as}_double() is not available in the kernel, but that
doesn't affect LibJS.
This commit is contained in:
committed by
Andreas Kling
parent
091d352526
commit
a5d4ef462c
Notes:
sideshowbarker
2024-07-18 20:16:37 +09:00
Author: https://github.com/linusg Commit: https://github.com/SerenityOS/serenity/commit/a5d4ef462cf Pull-request: https://github.com/SerenityOS/serenity/pull/6377
@@ -423,10 +423,8 @@ Value JSONObject::parse_json_value(GlobalObject& global_object, const JsonValue&
|
||||
return Value(parse_json_array(global_object, value.as_array()));
|
||||
if (value.is_null())
|
||||
return js_null();
|
||||
#if !defined(KERNEL)
|
||||
if (value.is_double())
|
||||
return Value(value.as_double());
|
||||
#endif
|
||||
if (value.is_number())
|
||||
return Value(value.to_i32(0));
|
||||
if (value.is_string())
|
||||
|
||||
Reference in New Issue
Block a user