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

Unified Diff: extensions/browser/extension_web_contents_observer.cc

Issue 2385533002: Replace usage of GURL(origin.Serialize()) with origin.GetURL() (Closed)
Patch Set: rebase and fix up some includes Created 4 years, 2 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
Index: extensions/browser/extension_web_contents_observer.cc
diff --git a/extensions/browser/extension_web_contents_observer.cc b/extensions/browser/extension_web_contents_observer.cc
index 6f065256712a5bac065cde5100c4f81c3b96ea8a..687fa00731800cd84ebd281f33cc68c6f71f1a10 100644
--- a/extensions/browser/extension_web_contents_observer.cc
+++ b/extensions/browser/extension_web_contents_observer.cc
@@ -24,6 +24,7 @@
#include "extensions/common/extension.h"
#include "extensions/common/extension_messages.h"
#include "extensions/common/view_type.h"
+#include "url/origin.h"
namespace extensions {
@@ -245,8 +246,8 @@ const Extension* ExtensionWebContentsObserver::GetExtensionFromFrame(
// schemes. With site isolation, this is still needed to exclude sandboxed
// extension frames with a unique origin.
if (origin.unique() ||
- site_url != content::SiteInstance::GetSiteForURL(
- browser_context, GURL(origin.Serialize())))
+ site_url != content::SiteInstance::GetSiteForURL(browser_context,
+ origin.GetURL()))
return nullptr;
}

Powered by Google App Engine
This is Rietveld 408576698