diff options
author | kalman@chromium.org <kalman@chromium.org@0039d316-1c4b-4281-b951-d872f2087c98> | 2013-09-10 00:22:16 +0000 |
---|---|---|
committer | kalman@chromium.org <kalman@chromium.org@0039d316-1c4b-4281-b951-d872f2087c98> | 2013-09-10 00:22:16 +0000 |
commit | d7cd1b00d3b5dc975d7d1b62b5cfea7afcfba5b8 (patch) | |
tree | 1f28c5f0b845ff9091637765e736d2e471304bf8 /extensions/common/extension_urls.cc | |
parent | d57410032e3b5e6d66e142ca6cdf559b5604165f (diff) | |
download | chromium_src-d7cd1b00d3b5dc975d7d1b62b5cfea7afcfba5b8.zip chromium_src-d7cd1b00d3b5dc975d7d1b62b5cfea7afcfba5b8.tar.gz chromium_src-d7cd1b00d3b5dc975d7d1b62b5cfea7afcfba5b8.tar.bz2 |
Namespace internal extension JavaScript modules with extensions:: so that they
can be identified in stack traces, and filtered out when showing to developers.
BUG=21734
Review URL: https://chromiumcodereview.appspot.com/23604050
git-svn-id: svn://svn.chromium.org/chrome/trunk/src@222149 0039d316-1c4b-4281-b951-d872f2087c98
Diffstat (limited to 'extensions/common/extension_urls.cc')
-rw-r--r-- | extensions/common/extension_urls.cc | 6 |
1 files changed, 4 insertions, 2 deletions
diff --git a/extensions/common/extension_urls.cc b/extensions/common/extension_urls.cc index 38a1fff..ba72a63 100644 --- a/extensions/common/extension_urls.cc +++ b/extensions/common/extension_urls.cc @@ -4,6 +4,7 @@ #include "extensions/common/extension_urls.h" +#include "base/strings/string_util.h" #include "base/strings/utf_string_conversions.h" #include "extensions/common/constants.h" #include "url/gurl.h" @@ -16,8 +17,9 @@ const char kSchemaUtils[] = "schemaUtils"; bool IsSourceFromAnExtension(const base::string16& source) { return GURL(source).SchemeIs(kExtensionScheme) || - source == base::UTF8ToUTF16(kEventBindings) || - source == base::UTF8ToUTF16(kSchemaUtils); + StartsWith(source, + base::ASCIIToUTF16("extensions::"), + true /* case-sensitive */); } } // namespace extensions |