Index: third_party/WebKit/Source/core/workers/WorkerGlobalScope.cpp |
diff --git a/third_party/WebKit/Source/core/workers/WorkerGlobalScope.cpp b/third_party/WebKit/Source/core/workers/WorkerGlobalScope.cpp |
index d20f8ba0ef0e7369470886c78ea4ffea62c3f814..0567dfa79c10de8936c870c1ade84a1360a19a72 100644 |
--- a/third_party/WebKit/Source/core/workers/WorkerGlobalScope.cpp |
+++ b/third_party/WebKit/Source/core/workers/WorkerGlobalScope.cpp |
@@ -267,7 +267,7 @@ EventTarget* WorkerGlobalScope::errorEventTarget() |
return this; |
} |
-void WorkerGlobalScope::logExceptionToConsole(const String& errorMessage, std::unique_ptr<SourceLocation> location) |
+void WorkerGlobalScope::exceptionThrown(const String& errorMessage, std::unique_ptr<SourceLocation> location) |
{ |
thread()->workerReportingProxy().reportException(errorMessage, std::move(location)); |
} |
@@ -355,7 +355,8 @@ void WorkerGlobalScope::countDeprecation(UseCounter::Feature feature) const |
void WorkerGlobalScope::exceptionUnhandled(const String& errorMessage, std::unique_ptr<SourceLocation> location) |
{ |
- addConsoleMessage(ConsoleMessage::create(JSMessageSource, ErrorMessageLevel, errorMessage, std::move(location))); |
+ if (WorkerThreadDebugger* debugger = WorkerThreadDebugger::from(thread()->isolate())) |
+ debugger->exceptionThrown(errorMessage, std::move(location)); |
} |
bool WorkerGlobalScope::isSecureContext(String& errorMessage, const SecureContextCheck privilegeContextCheck) const |