mirror of
https://github.com/zebrajr/node.git
synced 2026-01-15 12:15:26 +00:00
doc: fix usage of module.registerSync in comment
PR-URL: https://github.com/nodejs/node/pull/57328 Reviewed-By: Jacob Smith <jacob@frende.me> Reviewed-By: Luigi Pinca <luigipinca@gmail.com> Reviewed-By: James M Snell <jasnell@gmail.com>
This commit is contained in:
@@ -1226,7 +1226,7 @@ opt-in to using the non-default behavior:
|
||||
import { readFile } from 'node:fs/promises';
|
||||
|
||||
// Asynchronous version accepted by module.register(). This fix is not needed
|
||||
// for the synchronous version accepted by module.registerSync().
|
||||
// for the synchronous version accepted by module.registerHooks().
|
||||
export async function load(url, context, nextLoad) {
|
||||
const result = await nextLoad(url, context);
|
||||
if (result.format === 'commonjs') {
|
||||
|
||||
Reference in New Issue
Block a user