Index: extensions/browser/verified_contents.cc |
diff --git a/extensions/browser/verified_contents.cc b/extensions/browser/verified_contents.cc |
index fd60f313c59bb6cd35227e266625fb4c145157fc..eaf4c8fa93d6f763b25e2447ba163fe15f6bcb1e 100644 |
--- a/extensions/browser/verified_contents.cc |
+++ b/extensions/browser/verified_contents.cc |
@@ -43,12 +43,12 @@ const char kWebstoreKId[] = "webstore"; |
// Helper function to iterate over a list of dictionaries, returning the |
// dictionary that has |key| -> |value| in it, if any, or NULL. |
-DictionaryValue* FindDictionaryWithValue(const ListValue* list, |
- const std::string& key, |
- const std::string& value) { |
+const DictionaryValue* FindDictionaryWithValue(const ListValue* list, |
+ const std::string& key, |
+ const std::string& value) { |
for (const auto& i : *list) { |
- DictionaryValue* dictionary; |
- if (!i->GetAsDictionary(&dictionary)) |
+ const DictionaryValue* dictionary; |
+ if (!i.GetAsDictionary(&dictionary)) |
continue; |
std::string found_value; |
if (dictionary->GetString(key, &found_value) && found_value == value) |
@@ -248,20 +248,20 @@ bool VerifiedContents::GetPayload(const base::FilePath& path, |
// } |
// } |
// ] |
- DictionaryValue* dictionary = |
+ const DictionaryValue* dictionary = |
FindDictionaryWithValue(top_list, kDescriptionKey, kTreeHashPerFile); |
- DictionaryValue* signed_content = NULL; |
+ const DictionaryValue* signed_content = NULL; |
if (!dictionary || |
!dictionary->GetDictionaryWithoutPathExpansion(kSignedContentKey, |
&signed_content)) { |
return false; |
} |
- ListValue* signatures = NULL; |
+ const ListValue* signatures = NULL; |
if (!signed_content->GetList(kSignaturesKey, &signatures)) |
return false; |
- DictionaryValue* signature_dict = |
+ const DictionaryValue* signature_dict = |
FindDictionaryWithValue(signatures, kHeaderKidKey, kWebstoreKId); |
if (!signature_dict) |
return false; |