1
Fork 0
mirror of https://github.com/RGBCube/serenity synced 2025-07-25 15:37:46 +00:00

AK: Add new failable JsonArray::{append/set} functions

Move all old usages to the more explicit `JsonArray:must_{append/set}`
This commit is contained in:
Cameron Youell 2023-04-17 15:38:27 +10:00 committed by Andreas Kling
parent 3b00636288
commit 8134dccdc7
14 changed files with 28 additions and 25 deletions

View file

@ -164,7 +164,7 @@ ErrorOr<JsonValue> JsonParser::parse_array()
if (peek() == ']')
break;
auto element = TRY(parse_helper());
array.append(move(element));
array.must_append(move(element));
ignore_while(is_space);
if (peek() == ']')
break;