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

Unified Diff: components/autofill/content/renderer/password_generation_agent.cc

Issue 2972333002: autofill : Use ContainsValue() instead of std::find() in components/autofill (Closed)
Patch Set: Created 3 years, 5 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/autofill/content/renderer/password_generation_agent.cc
diff --git a/components/autofill/content/renderer/password_generation_agent.cc b/components/autofill/content/renderer/password_generation_agent.cc
index e7986765a8e42dcc5699bd0ad4950641937daf1f..214d484af3ab8a33256ef71dba6676b94ea4c350 100644
--- a/components/autofill/content/renderer/password_generation_agent.cc
+++ b/components/autofill/content/renderer/password_generation_agent.cc
@@ -58,7 +58,7 @@ bool GetAccountCreationPasswordFields(
}
bool ContainsURL(const std::vector<GURL>& urls, const GURL& url) {
- return std::find(urls.begin(), urls.end(), url) != urls.end();
+ return base::ContainsValue(urls, url);
vabr (Chromium) 2017/07/09 18:23:59 Please also #include "base/stl_util.h" in this fil
deejay 2017/07/10 03:47:16 Done.
}
// Calculates the signature of |form| and searches it in |forms|.

Powered by Google App Engine
This is Rietveld 408576698