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

Unified Diff: chrome/browser/chromeos/platform_keys/platform_keys_service.cc

Issue 1715683002: chrome: Use base's ContainsValue helper function instead of std::find (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@master
Patch Set: Updated as per latest code Created 4 years, 10 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: chrome/browser/chromeos/platform_keys/platform_keys_service.cc
diff --git a/chrome/browser/chromeos/platform_keys/platform_keys_service.cc b/chrome/browser/chromeos/platform_keys/platform_keys_service.cc
index 0eae654ef03c8f8b49b1539f55ac8948ec9dd924..40cbd9a603e4c9fb4c840db56c077bd9bab7e3d2 100644
--- a/chrome/browser/chromeos/platform_keys/platform_keys_service.cc
+++ b/chrome/browser/chromeos/platform_keys/platform_keys_service.cc
@@ -12,6 +12,7 @@
#include "base/bind_helpers.h"
#include "base/callback.h"
#include "base/macros.h"
+#include "base/stl_util.h"
#include "base/values.h"
#include "chrome/browser/chromeos/platform_keys/platform_keys.h"
#include "content/public/browser/browser_thread.h"
@@ -423,8 +424,7 @@ class PlatformKeysService::SelectTask : public Task {
certificate->os_cert_handle(), &unused_key_size, &actual_key_type);
const std::vector<net::X509Certificate::PublicKeyType>& accepted_types =
request_.certificate_key_types;
- if (std::find(accepted_types.begin(), accepted_types.end(),
- actual_key_type) == accepted_types.end()) {
+ if (!ContainsValue(accepted_types, actual_key_type)) {
sky 2016/03/02 17:19:34 nit: no {}
chakshu 2016/03/07 08:10:46 Done.
continue;
}
}

Powered by Google App Engine
This is Rietveld 408576698