mirror of
https://github.com/LadybirdBrowser/ladybird.git
synced 2025-09-08 18:46:03 +00:00
LibWeb: Restore handling of the serenity:ladybird/headless capability
This was refactored a bit incorrectly in d8fde14
.
This commit is contained in:
parent
9347db6f91
commit
792258afe8
Notes:
sideshowbarker
2024-07-17 00:54:56 +09:00
Author: https://github.com/trflynn89
Commit: 792258afe8
Pull-request: https://github.com/SerenityOS/serenity/pull/17274
Reviewed-by: https://github.com/linusg
1 changed files with 1 additions and 1 deletions
|
@ -52,7 +52,7 @@ static Response deserialize_as_ladybird_options(JsonValue value)
|
|||
|
||||
auto const& object = value.as_object();
|
||||
|
||||
if (auto headless = object.get_bool("headless"sv); headless.has_value())
|
||||
if (auto headless = object.get("headless"sv); headless.has_value() && !headless->is_bool())
|
||||
return Error::from_code(ErrorCode::InvalidArgument, "Extension capability serenity:ladybird/headless must be a boolean"sv);
|
||||
|
||||
return value;
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue