From 8303dd1c8cd9cc39d8f7d5450b1f0bf1d16451ee Mon Sep 17 00:00:00 2001 From: dnlup Date: Thu, 21 Mar 2019 16:38:52 +0100 Subject: [PATCH] module: remove usage of require('util') in `esm/translators.js` Use `require('internal/util/debuglog').debuglog` and `require('internal/util').promisify` instead of `require('util').debuglog` and `require('util').promisify` in `lib/internal/modules/translators.js`. PR-URL: https://github.com/nodejs/node/pull/26806 Refs: https://github.com/nodejs/node/issues/26546 Reviewed-By: James M Snell Reviewed-By: Ruben Bridgewater --- lib/internal/modules/esm/translators.js | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) diff --git a/lib/internal/modules/esm/translators.js b/lib/internal/modules/esm/translators.js index 25552cff0e8f47..e33fc85993a2b2 100644 --- a/lib/internal/modules/esm/translators.js +++ b/lib/internal/modules/esm/translators.js @@ -19,7 +19,8 @@ const { StringPrototype } = primordials; const { URL } = require('url'); -const { debuglog, promisify } = require('util'); +const { debuglog } = require('internal/util/debuglog'); +const { promisify } = require('internal/util'); const esmLoader = require('internal/process/esm_loader'); const readFileAsync = promisify(fs.readFile);