| Index: extensions/browser/api/execute_code_function.cc
|
| diff --git a/extensions/browser/api/execute_code_function.cc b/extensions/browser/api/execute_code_function.cc
|
| index 21845aa47ec48b07e549e7b449c10d0641799358..1cb5f0f2be5576af1887110fcff6a92408f0935f 100644
|
| --- a/extensions/browser/api/execute_code_function.cc
|
| +++ b/extensions/browser/api/execute_code_function.cc
|
| @@ -129,7 +129,7 @@ bool ExecuteCodeFunction::Execute(const std::string& code_string) {
|
| if (!executor)
|
| return false;
|
|
|
| - if (!extension())
|
| + if (!extension() && !IsWebView())
|
| return false;
|
|
|
| ScriptExecutor::ScriptType script_type = ScriptExecutor::JAVASCRIPT;
|
| @@ -162,7 +162,7 @@ bool ExecuteCodeFunction::Execute(const std::string& code_string) {
|
| CHECK_NE(UserScript::UNDEFINED, run_at);
|
|
|
| executor->ExecuteScript(
|
| - extension()->id(),
|
| + host_id_,
|
| script_type,
|
| code_string,
|
| frame_scope,
|
|
|