1
Fork 0
mirror of https://github.com/RGBCube/serenity synced 2025-05-31 18:08:12 +00:00

LibGUI: Replace uses of JsonObject::get_deprecated()/get_ptr()

This commit is contained in:
Sam Atkins 2022-12-21 17:27:41 +00:00 committed by Tim Flynn
parent 4313c17d95
commit 2fce19a451
3 changed files with 10 additions and 8 deletions

View file

@ -56,8 +56,8 @@ ErrorOr<void> CommonLocationsProvider::load_from_json(StringView json_path)
if (!entry_value.is_object())
continue;
auto entry = entry_value.as_object();
auto name = entry.get_deprecated("name"sv).to_deprecated_string();
auto path = entry.get_deprecated("path"sv).to_deprecated_string();
auto name = entry.get_deprecated_string("name"sv).value_or({});
auto path = entry.get_deprecated_string("path"sv).value_or({});
TRY(s_common_locations.try_append({ name, path }));
}