| Index: chrome/common/extensions/extension_file_util.cc
|
| diff --git a/chrome/common/extensions/extension_file_util.cc b/chrome/common/extensions/extension_file_util.cc
|
| index ca31d830aca36d70e599b96aa566790a7e0c93c6..47996c1f3c264ecadc217c9e85511f75cf911284 100644
|
| --- a/chrome/common/extensions/extension_file_util.cc
|
| +++ b/chrome/common/extensions/extension_file_util.cc
|
| @@ -292,9 +292,11 @@ bool ValidateExtension(const Extension* extension, std::string* error) {
|
| // Validate background page location, except for hosted apps, which should use
|
| // an external URL. Background page for hosted apps are verified when the
|
| // extension is created (in Extension::InitFromValue)
|
| - if (!extension->background_url().is_empty() && !extension->is_hosted_app()) {
|
| + if (extension->has_background_page() &&
|
| + !extension->is_hosted_app() &&
|
| + extension->background_scripts().empty()) {
|
| FilePath page_path = ExtensionURLToRelativeFilePath(
|
| - extension->background_url());
|
| + extension->GetBackgroundURL());
|
| const FilePath path = extension->GetResource(page_path).GetFilePath();
|
| if (path.empty() || !file_util::PathExists(path)) {
|
| *error =
|
|
|