File tree Expand file tree Collapse file tree 1 file changed +1
-10
lines changed
Expand file tree Collapse file tree 1 file changed +1
-10
lines changed Original file line number Diff line number Diff line change @@ -2684,16 +2684,7 @@ inline void AsyncWorker::OnWorkComplete(
26842684 self->OnError (Error::New (self->_env , self->_error ));
26852685 }
26862686 } catch (const Error& e) {
2687- // A JS or N-API exception was thrown, and propagated as a C++ exception.
2688- // But throwing a JS exception here would have no effect because there
2689- // is no JS on the callstack.
2690-
2691- // TODO: Print the exception details and abort, just like Node.js normally
2692- // does for unhandled exceptions. But there is no N-API function for that.
2693- // For now just assert, so at least the exception message is discoverable
2694- // in a debug build.
2695- const char * message = e.what ();
2696- assert (false );
2687+ e.ThrowAsJavaScriptException ();
26972688 }
26982689 }
26992690 delete self;
You can’t perform that action at this time.
0 commit comments