Index: chrome/common/extensions/extension.cc |
=================================================================== |
--- chrome/common/extensions/extension.cc (revision 19502) |
+++ chrome/common/extensions/extension.cc (working copy) |
@@ -12,6 +12,7 @@ |
#include "base/string_util.h" |
#include "base/third_party/nss/blapi.h" |
#include "base/third_party/nss/sha256.h" |
+#include "chrome/common/chrome_constants.h" |
#include "chrome/common/extensions/extension_error_reporter.h" |
#include "chrome/common/extensions/extension_error_utils.h" |
#include "chrome/common/extensions/user_script.h" |
@@ -199,6 +200,13 @@ |
} |
// static |
+bool Extension::IsExtension(const FilePath& file_name) { |
+ return file_name.MatchesExtension( |
+ FilePath::StringType(FILE_PATH_LITERAL(".")) + |
+ chrome::kExtensionFileExtension); |
+} |
+ |
+// static |
bool Extension::IdIsValid(const std::string& id) { |
// Verify that the id is legal. |
if (id.size() != (kIdSize * 2)) |