Chromium Code Reviews
chromiumcodereview-hr@appspot.gserviceaccount.com (chromiumcodereview-hr) | Please choose your nickname with Settings | Help | Chromium Project | Gerrit Changes | Sign out
(64)

Unified Diff: components/ntp_snippets/category_rankers/click_based_category_ranker.cc

Issue 2740143002: Change base::Value::ListStorage to std::vector<base::Value> (Closed)
Patch Set: Comment Updates Created 3 years, 9 months ago
Use n/p to move between diff chunks; N/P to move between comments. Draft comments are only viewable by you.
Jump to:
View side-by-side diff with in-line comments
Download patch
Index: components/ntp_snippets/category_rankers/click_based_category_ranker.cc
diff --git a/components/ntp_snippets/category_rankers/click_based_category_ranker.cc b/components/ntp_snippets/category_rankers/click_based_category_ranker.cc
index 653a68f9ac21908e49d30fa3134c833bb3da1bac..5dc8882fc08832399655a7a468ff6ee8a9b97b2a 100644
--- a/components/ntp_snippets/category_rankers/click_based_category_ranker.cc
+++ b/components/ntp_snippets/category_rankers/click_based_category_ranker.cc
@@ -413,9 +413,9 @@ bool ClickBasedCategoryRanker::ReadOrderFromPrefs(
return false;
}
- for (const std::unique_ptr<base::Value>& value : *list) {
- base::DictionaryValue* dictionary;
- if (!value->GetAsDictionary(&dictionary)) {
+ for (const base::Value& value : *list) {
+ const base::DictionaryValue* dictionary;
+ if (!value.GetAsDictionary(&dictionary)) {
LOG(DFATAL) << "Failed to parse category data from prefs param "
<< prefs::kClickBasedCategoryRankerOrderWithClicks
<< " into dictionary.";

Powered by Google App Engine
This is Rietveld 408576698