Update for M98

This commit is contained in:
Alexander David Frick 2021-11-11 11:13:38 -06:00 committed by GitHub
parent e04e7cc2ef
commit ba7e522ad6
No known key found for this signature in database
GPG key ID: 4AEE18F83AFDEB23

View file

@ -1342,11 +1342,9 @@ std::vector<std::unique_ptr<TemplateURLData>> GetPrepopulatedTemplateURLData(
if (!list)
return t_urls;
size_t num_engines = list->GetList().size();
for (size_t i = 0; i != num_engines; ++i) {
const base::DictionaryValue* engine;
if (list->GetDictionary(i, &engine)) {
auto t_url = TemplateURLDataFromOverrideDictionary(*engine);
for (const base::Value& engine : list->GetList()) {
if (engine.is_dict()) {
auto t_url = TemplateURLDataFromOverrideDictionary(engine);
if (t_url)
t_urls.push_back(std::move(t_url));
}