AK+Everywhere: Store JSON strings as String

This commit is contained in:
Timothy Flynn 2025-02-17 13:21:07 -05:00 committed by Tim Flynn
commit bc54c0cdfb
Notes: github-actions[bot] 2025-02-21 00:29:21 +00:00
33 changed files with 163 additions and 152 deletions

View file

@ -50,8 +50,8 @@ void FrameActor::send_frame_update_message()
if (auto tab_actor = m_tab.strong_ref()) {
JsonObject frame;
frame.set("id"sv, tab_actor->description().id);
frame.set("title"sv, tab_actor->description().title);
frame.set("url"sv, tab_actor->description().url);
frame.set("title"sv, MUST(String::from_byte_string(tab_actor->description().title)));
frame.set("url"sv, MUST(String::from_byte_string(tab_actor->description().url)));
frames.must_append(move(frame));
}
@ -76,8 +76,8 @@ JsonObject FrameActor::serialize_target() const
target.set("actor"sv, name());
if (auto tab_actor = m_tab.strong_ref()) {
target.set("title"sv, tab_actor->description().title);
target.set("url"sv, tab_actor->description().url);
target.set("title"sv, MUST(String::from_byte_string(tab_actor->description().title)));
target.set("url"sv, MUST(String::from_byte_string(tab_actor->description().url)));
target.set("browsingContextID"sv, tab_actor->description().id);
target.set("outerWindowID"sv, tab_actor->description().id);
target.set("isTopLevelTarget"sv, true);