mirror of
https://github.com/LadybirdBrowser/ladybird.git
synced 2024-08-17 09:20:28 +03:00
AK: Use JsonArray::append
when parsing array
This commit is contained in:
parent
8134dccdc7
commit
ada6dbf636
Notes:
sideshowbarker
2024-07-17 06:38:11 +09:00
Author: https://github.com/cammo1123 Commit: https://github.com/SerenityOS/serenity/commit/ada6dbf636 Pull-request: https://github.com/SerenityOS/serenity/pull/18409 Reviewed-by: https://github.com/gmta Reviewed-by: https://github.com/krkk
@ -164,7 +164,7 @@ ErrorOr<JsonValue> JsonParser::parse_array()
|
||||
if (peek() == ']')
|
||||
break;
|
||||
auto element = TRY(parse_helper());
|
||||
array.must_append(move(element));
|
||||
TRY(array.append(move(element)));
|
||||
ignore_while(is_space);
|
||||
if (peek() == ']')
|
||||
break;
|
||||
|
Loading…
Reference in New Issue
Block a user