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

Unified Diff: components/ntp_snippets/remote/remote_suggestions_fetcher.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/remote/remote_suggestions_fetcher.cc
diff --git a/components/ntp_snippets/remote/remote_suggestions_fetcher.cc b/components/ntp_snippets/remote/remote_suggestions_fetcher.cc
index 2f9b64334f52e5fe57bdb6dd508593042ea330fc..f8c16529c70e9efaf93f6764e0f46f4d5cd18bbe 100644
--- a/components/ntp_snippets/remote/remote_suggestions_fetcher.cc
+++ b/components/ntp_snippets/remote/remote_suggestions_fetcher.cc
@@ -125,7 +125,7 @@ bool AddSuggestionsFromListValue(bool content_suggestions_api,
const base::Time& fetch_time) {
for (const auto& value : list) {
const base::DictionaryValue* dict = nullptr;
- if (!value->GetAsDictionary(&dict)) {
+ if (!value.GetAsDictionary(&dict)) {
return false;
}
@@ -515,7 +515,7 @@ bool RemoteSuggestionsFetcher::JsonToSnippets(
std::string utf8_title;
int remote_category_id = -1;
const base::DictionaryValue* category_value = nullptr;
- if (!(v->GetAsDictionary(&category_value) &&
+ if (!(v.GetAsDictionary(&category_value) &&
category_value->GetString("localizedTitle", &utf8_title) &&
category_value->GetInteger("id", &remote_category_id) &&
(remote_category_id > 0))) {

Powered by Google App Engine
This is Rietveld 408576698