mirror of
https://github.com/electron/electron.git
synced 2026-04-10 03:01:51 -04:00
refactor: replace use of deprecated base::JSONWriter::WriteJson() (#41215)
* refactor: use base::WriteJson() in ListValueToNSArray() refactor: use base::WriteJson() in DictionaryValueToNSDictionary() * refactor: use base::WriteJson() in Debugger::SendCommand() * refactor: use base::WriteJson() in ScriptingExecuteScriptFunction::Run() * refactor: use base::WriteJson() in HandleAccessibilityRequestCallback()
This commit is contained in:
@@ -295,11 +295,8 @@ void HandleAccessibilityRequestCallback(
|
||||
|
||||
data.Set(kBrowsersField, std::move(window_list));
|
||||
|
||||
std::string json_string;
|
||||
base::JSONWriter::Write(data, &json_string);
|
||||
|
||||
std::move(callback).Run(
|
||||
base::MakeRefCounted<base::RefCountedString>(std::move(json_string)));
|
||||
std::move(callback).Run(base::MakeRefCounted<base::RefCountedString>(
|
||||
base::WriteJson(data).value_or("")));
|
||||
}
|
||||
|
||||
} // namespace
|
||||
|
||||
Reference in New Issue
Block a user