diff --git a/src/node_main_instance.cc b/src/node_main_instance.cc index 6f240d7e809f8e..998cf260de2a62 100644 --- a/src/node_main_instance.cc +++ b/src/node_main_instance.cc @@ -102,12 +102,8 @@ NodeMainInstance::~NodeMainInstance() { if (!owns_isolate_) { return; } - // TODO(addaleax): Reverse the order of these calls. The fact that we first - // dispose the Isolate is a temporary workaround for - // https://github.com/nodejs/node/issues/31752 -- V8 should not be posting - // platform tasks during Dispose(), but it does in some WASM edge cases. - isolate_->Dispose(); platform_->UnregisterIsolate(isolate_); + isolate_->Dispose(); } int NodeMainInstance::Run() {