Skip to content

Commit d0e42ff

Browse files
gulbakiRafaelGSS
authored andcommitted
repl: avoid deprecated require.extensions in tab completion
PR-URL: #58653 Fixes: #58641 Reviewed-By: Ethan Arrowood <[email protected]> Reviewed-By: Dario Piotrowicz <[email protected]> Reviewed-By: Marco Ippolito <[email protected]> Reviewed-By: Juan José Arboleda <[email protected]> Reviewed-By: Luigi Pinca <[email protected]>
1 parent d9c2b70 commit d0e42ff

File tree

1 file changed

+1
-1
lines changed

1 file changed

+1
-1
lines changed

lib/repl.js

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1359,7 +1359,7 @@ function complete(line, callback) {
13591359
filter = completeOn;
13601360
if (this.allowBlockingCompletions) {
13611361
const subdir = match[2] || '';
1362-
const extensions = ObjectKeys(this.context.require.extensions);
1362+
const extensions = ObjectKeys(CJSModule._extensions);
13631363
const indexes = ArrayPrototypeMap(extensions,
13641364
(extension) => `index${extension}`);
13651365
ArrayPrototypePush(indexes, 'package.json', 'index');

0 commit comments

Comments
 (0)