| Index: chrome/common/extensions/features/api_feature.cc
|
| diff --git a/chrome/common/extensions/features/api_feature.cc b/chrome/common/extensions/features/api_feature.cc
|
| index d53d105bc267bcbac7ecb7c26ed9da1fad32d633..edb9317b840f8eff3a55bbe3fe236f4e224f2f52 100644
|
| --- a/chrome/common/extensions/features/api_feature.cc
|
| +++ b/chrome/common/extensions/features/api_feature.cc
|
| @@ -6,8 +6,8 @@
|
|
|
| namespace extensions {
|
|
|
| -APIFeature::APIFeature() : internal_(false) {
|
| -}
|
| +APIFeature::APIFeature()
|
| + : internal_(false), blocked_in_service_worker_(false) {}
|
|
|
| APIFeature::~APIFeature() {
|
| }
|
| @@ -16,12 +16,17 @@ bool APIFeature::IsInternal() const {
|
| return internal_;
|
| }
|
|
|
| +bool APIFeature::IsBlockedInServiceWorker() const {
|
| + return blocked_in_service_worker_;
|
| +}
|
| +
|
| std::string APIFeature::Parse(const base::DictionaryValue* value) {
|
| std::string error = SimpleFeature::Parse(value);
|
| if (!error.empty())
|
| return error;
|
|
|
| value->GetBoolean("internal", &internal_);
|
| + value->GetBoolean("blocked_in_service_worker", &blocked_in_service_worker_);
|
|
|
| if (GetContexts()->empty())
|
| return name() + ": API features must specify at least one context.";
|
| @@ -29,4 +34,4 @@ std::string APIFeature::Parse(const base::DictionaryValue* value) {
|
| return std::string();
|
| }
|
|
|
| -} // namespace
|
| +} // namespace extensions
|
|
|