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

Unified Diff: extensions/common/features/base_feature_provider.cc

Issue 1272823003: Update SplitString calls to new form (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@master
Patch Set: Created 5 years, 4 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 | « extensions/common/csp_validator.cc ('k') | extensions/common/manifest.cc » ('j') | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: extensions/common/features/base_feature_provider.cc
diff --git a/extensions/common/features/base_feature_provider.cc b/extensions/common/features/base_feature_provider.cc
index 472e1f55122b89a44fb7aa0973e7c6982560aa13..cae08d6243e78b1700854e57d5077ff47dd17cf1 100644
--- a/extensions/common/features/base_feature_provider.cc
+++ b/extensions/common/features/base_feature_provider.cc
@@ -52,8 +52,8 @@ BaseFeatureProvider::BaseFeatureProvider(const base::DictionaryValue& root,
if (iter.value().GetType() == base::Value::TYPE_DICTIONARY) {
linked_ptr<SimpleFeature> feature((*factory_)());
- std::vector<std::string> split;
- base::SplitString(iter.key(), '.', &split);
+ std::vector<std::string> split = base::SplitString(
+ iter.key(), ".", base::TRIM_WHITESPACE, base::SPLIT_WANT_ALL);
// Push parent features on the stack, starting with the current feature.
// If one of the features has "noparent" set, stop pushing features on
@@ -171,8 +171,8 @@ Feature* BaseFeatureProvider::GetParent(Feature* feature) const {
if (feature->no_parent())
return nullptr;
- std::vector<std::string> split;
- base::SplitString(feature->name(), '.', &split);
+ std::vector<std::string> split = base::SplitString(
+ feature->name(), ".", base::TRIM_WHITESPACE, base::SPLIT_WANT_ALL);
if (split.size() < 2)
return nullptr;
split.pop_back();
« no previous file with comments | « extensions/common/csp_validator.cc ('k') | extensions/common/manifest.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698