Index: src/inspector/v8-runtime-agent-impl.cc |
diff --git a/src/inspector/v8-runtime-agent-impl.cc b/src/inspector/v8-runtime-agent-impl.cc |
index d324d343bc25b9c5cdf616ba96cf11fe92b973e5..081746c7508e4b48dcbd3edad1a11190794a0785 100644 |
--- a/src/inspector/v8-runtime-agent-impl.cc |
+++ b/src/inspector/v8-runtime-agent-impl.cc |
@@ -750,6 +750,9 @@ Response V8RuntimeAgentImpl::enable() { |
m_state->setBoolean(V8RuntimeAgentImplState::runtimeEnabled, true); |
m_inspector->enableStackCapturingIfNeeded(); |
m_session->reportAllContexts(this); |
+ m_session->setCustomObjectFormatterEnabled(m_state->booleanProperty( |
dgozman
2017/02/27 18:44:56
And we should not restore anything in enable. It j
kozy
2017/02/27 19:57:13
Ok, then we should forbid this method on disabled
|
+ V8RuntimeAgentImplState::customObjectFormatterEnabled, false)); |
+ |
V8ConsoleMessageStorage* storage = |
m_inspector->ensureConsoleMessageStorage(m_session->contextGroupId()); |
for (const auto& message : storage->messages()) { |
@@ -764,6 +767,7 @@ Response V8RuntimeAgentImpl::disable() { |
m_state->setBoolean(V8RuntimeAgentImplState::runtimeEnabled, false); |
m_inspector->disableStackCapturingIfNeeded(); |
m_session->discardInjectedScripts(); |
+ m_session->setCustomObjectFormatterEnabled(false); |
reset(); |
m_inspector->client()->endEnsureAllContextsInGroup( |
m_session->contextGroupId()); |