diff --git a/lib/internal/modules/cjs/loader.js b/lib/internal/modules/cjs/loader.js index 880575964b742b..ef56540bc43757 100644 --- a/lib/internal/modules/cjs/loader.js +++ b/lib/internal/modules/cjs/loader.js @@ -23,7 +23,7 @@ const { NativeModule } = require('internal/bootstrap/loaders'); const { pathToFileURL } = require('internal/url'); -const util = require('util'); +const { deprecate } = require('internal/util'); const vm = require('vm'); const assert = require('internal/assert'); const fs = require('fs'); @@ -182,8 +182,7 @@ function debug(...args) { debuglog(...args); } -Module._debug = util.deprecate(debug, 'Module._debug is deprecated.', - 'DEP0077'); +Module._debug = deprecate(debug, 'Module._debug is deprecated.', 'DEP0077'); // Given a module name, and a list of paths to test, returns the first // matching file in the following precedence.