Index: src/api.cc |
diff --git a/src/api.cc b/src/api.cc |
index b962909ee29470f91bf061d21cf1974c15ec575d..e1a6dcd9cef807d90494550de89b3ddd33ca165e 100644 |
--- a/src/api.cc |
+++ b/src/api.cc |
@@ -1976,10 +1976,11 @@ static bool InstantiateModule(Local<Module> v8_module, |
isolate->ThrowIllegalOperation(); |
return false; |
} |
- if (!requested_module->Instantiate(v8_context, callback, callback_data)) { |
+ module->requested_modules()->set(i, *Utils::OpenHandle(*requested_module)); |
+ if (!InstantiateModule(requested_module, v8_context, callback, |
+ callback_data)) { |
return false; |
} |
- module->requested_modules()->set(i, *Utils::OpenHandle(*requested_module)); |
} |
// Resolve imports. |