Skip to content

Commit

Permalink
fixup! module: make CJS load from ESM loader
Browse files Browse the repository at this point in the history
  • Loading branch information
aduh95 committed May 14, 2023
1 parent 8a602a2 commit 0eee2c3
Showing 1 changed file with 2 additions and 2 deletions.
4 changes: 2 additions & 2 deletions lib/internal/modules/esm/module_job.js
Original file line number Diff line number Diff line change
Expand Up @@ -192,10 +192,10 @@ class ModuleJob {
}

runSync() {
assert(this.module instanceof ModuleWrap);
if (this.instantiated !== undefined) {
return this.instantiated;
return { __proto__: null, module: this.module };
}
assert(this.module instanceof ModuleWrap);

// TODO: better handle errors
this.module.instantiate();
Expand Down

0 comments on commit 0eee2c3

Please sign in to comment.