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

Unified Diff: extensions/renderer/v8_schema_registry.cc

Issue 2275813002: Revert of Signal extension API schema corruption to the browser process. (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@master
Patch Set: Created 4 years, 4 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
« no previous file with comments | « extensions/common/extension_messages.h ('k') | no next file » | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: extensions/renderer/v8_schema_registry.cc
diff --git a/extensions/renderer/v8_schema_registry.cc b/extensions/renderer/v8_schema_registry.cc
index f2ca4baa8c0c63a85854d09c6673cf26030670e9..2db2bb30dae2033d07346734a0b6e496e4c3be3f 100644
--- a/extensions/renderer/v8_schema_registry.cc
+++ b/extensions/renderer/v8_schema_registry.cc
@@ -11,9 +11,7 @@
#include "base/logging.h"
#include "base/values.h"
#include "content/public/child/v8_value_converter.h"
-#include "content/public/renderer/render_thread.h"
#include "extensions/common/extension_api.h"
-#include "extensions/common/extension_messages.h"
#include "extensions/renderer/object_backed_native_handler.h"
#include "extensions/renderer/script_context.h"
#include "extensions/renderer/v8_helpers.h"
@@ -133,16 +131,7 @@
const base::DictionaryValue* schema =
ExtensionAPI::GetSharedInstance()->GetSchema(api);
-
- // If the schema for |api| cannot be loaded then return an empty object, but
- // also notify the browser so that it can take appropriate action.
- // See http://crbug.com/121424.
- if (!schema) {
- content::RenderThread::Get()->Send(
- new ExtensionHostMsg_NotifyBadExtensionApiSchema(api));
- return v8::Local<v8::Object>();
- }
-
+ CHECK(schema) << api;
std::unique_ptr<V8ValueConverter> v8_value_converter(
V8ValueConverter::create());
v8::Local<v8::Value> value = v8_value_converter->ToV8Value(schema, context);
« no previous file with comments | « extensions/common/extension_messages.h ('k') | no next file » | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698