зеркало из https://github.com/electron/electron.git
refactor: replace base::Value::DeepCopy and CreateDeepCopy with Clone (#14420)
This commit is contained in:
Родитель
8e1452d316
Коммит
aa01a7337c
|
@ -131,7 +131,8 @@ void Debugger::SendCommand(mate::Arguments* args) {
|
|||
request.SetInteger("id", request_id);
|
||||
request.SetString("method", method);
|
||||
if (!command_params.empty())
|
||||
request.Set("params", base::WrapUnique(command_params.DeepCopy()));
|
||||
request.Set("params",
|
||||
base::Value::ToUniquePtrValue(command_params.Clone()));
|
||||
|
||||
std::string json_args;
|
||||
base::JSONWriter::Write(request, &json_args);
|
||||
|
|
|
@ -53,7 +53,7 @@ void RenderProcessPreferences::UpdateCache() {
|
|||
|
||||
cached_entries_.Clear();
|
||||
for (const auto& iter : entries_)
|
||||
cached_entries_.Append(iter.second->CreateDeepCopy());
|
||||
cached_entries_.Append(base::Value::ToUniquePtrValue(iter.second->Clone()));
|
||||
cache_needs_update_ = false;
|
||||
}
|
||||
|
||||
|
|
Загрузка…
Ссылка в новой задаче