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

Unified Diff: chrome/browser/extensions/api/file_system/file_system_api.cc

Issue 2961033002: Use ContainsValue() instead of std::find() in chrome/browser/extensions (Closed)
Patch Set: Reverted code changes in language_settings_private_api.cc:307 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
« no previous file with comments | « no previous file | chrome/browser/extensions/api/gcm/gcm_apitest.cc » ('j') | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: chrome/browser/extensions/api/file_system/file_system_api.cc
diff --git a/chrome/browser/extensions/api/file_system/file_system_api.cc b/chrome/browser/extensions/api/file_system/file_system_api.cc
index 9ca75b7f57bbfe4f2f8045029c28c5df10a499a9..159fb5cc24c46fe7e56a883805914b4f5939cac5 100644
--- a/chrome/browser/extensions/api/file_system/file_system_api.cc
+++ b/chrome/browser/extensions/api/file_system/file_system_api.cc
@@ -18,6 +18,7 @@
#include "base/macros.h"
#include "base/memory/ptr_util.h"
#include "base/path_service.h"
+#include "base/stl_util.h"
#include "base/strings/string_util.h"
#include "base/strings/stringprintf.h"
#include "base/strings/sys_string_conversions.h"
@@ -781,8 +782,7 @@ void FileSystemChooseEntryFunction::BuildFileTypeInfo(
// If we still need to find suggested_extension, hunt for it inside the
// extensions returned from GetFileTypesFromAcceptOption.
if (need_suggestion &&
- std::find(extensions.begin(), extensions.end(),
- suggested_extension) != extensions.end()) {
+ base::ContainsValue(extensions, suggested_extension)) {
need_suggestion = false;
}
}
« no previous file with comments | « no previous file | chrome/browser/extensions/api/gcm/gcm_apitest.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698