mirror of
https://github.com/LadybirdBrowser/ladybird
synced 2026-05-05 06:32:30 +02:00
AK+Everywhere: Store JSON strings as String
This commit is contained in:
Notes:
github-actions[bot]
2025-02-21 00:29:21 +00:00
Author: https://github.com/trflynn89 Commit: https://github.com/LadybirdBrowser/ladybird/commit/bc54c0cdfbf Pull-request: https://github.com/LadybirdBrowser/ladybird/pull/3631 Reviewed-by: https://github.com/awesomekling ✅
@@ -749,7 +749,7 @@ void ArgsParser::autocomplete(FILE* file, StringView program_name, ReadonlySpan<
|
||||
|
||||
auto write_completion = [&](auto format, auto& option, auto has_invariant, auto... args) {
|
||||
JsonObject object;
|
||||
object.set("completion"sv, ByteString::formatted(StringView { format, strlen(format) }, args...));
|
||||
object.set("completion"sv, MUST(String::formatted(StringView { format, strlen(format) }, args...)));
|
||||
object.set("static_offset"sv, 0);
|
||||
object.set("invariant_offset"sv, has_invariant ? option_to_complete.length() : 0u);
|
||||
object.set("display_trivia"sv, StringView { option.help_string, strlen(option.help_string) });
|
||||
|
||||
Reference in New Issue
Block a user