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

Unified Diff: extensions/renderer/script_context.cc

Issue 2183443002: Fix extension bindings injection for iframes (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@2785
Patch Set: Created 4 years, 5 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/renderer/script_context.cc
diff --git a/extensions/renderer/script_context.cc b/extensions/renderer/script_context.cc
index 587087bd1a5e05af173a28c3375f7c346ca4e205..d20d21d77248a9bb3160722f3c10c518f1a4cda0 100644
--- a/extensions/renderer/script_context.cc
+++ b/extensions/renderer/script_context.cc
@@ -108,7 +108,7 @@ ScriptContext::ScriptContext(const v8::Local<v8::Context>& v8_context,
effective_context_type_(effective_context_type),
safe_builtins_(this),
isolate_(v8_context->GetIsolate()),
- url_(web_frame_ ? GetDataSourceURLForFrame(web_frame_) : GURL()),
+ url_(web_frame_ ? GURL(web_frame_->document().url()) : GURL()),
runner_(new Runner(this)) {
VLOG(1) << "Created context:\n" << GetDebugString();
gin::PerContextData* gin_data = gin::PerContextData::From(v8_context);
« no previous file with comments | « chrome/test/data/extensions/api_test/bindings/message_sender/public.html ('k') | extensions/renderer/script_context_set.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698