Skip to content

Commit

Permalink
lib: remove usage of require('util')
Browse files Browse the repository at this point in the history
Remove the usage of `require('util').inspect`.

PR-URL: #26779
Refs: #26546
Reviewed-By: Ruben Bridgewater <[email protected]>
Reviewed-By: Yongsheng Zhang <[email protected]>
  • Loading branch information
dnlup authored and targos committed Mar 27, 2019
1 parent 64a9229 commit bf2b57e
Showing 1 changed file with 2 additions and 2 deletions.
4 changes: 2 additions & 2 deletions lib/internal/encoding.js
Original file line number Diff line number Diff line change
Expand Up @@ -327,7 +327,7 @@ class TextEncoder {
});
obj.encoding = this.encoding;
// Lazy to avoid circular dependency
return require('util').inspect(obj, opts);
return require('internal/util/inspect').inspect(obj, opts);
}
}

Expand Down Expand Up @@ -528,7 +528,7 @@ function makeTextDecoderJS() {
obj[kHandle] = this[kHandle];
}
// Lazy to avoid circular dependency
return require('util').inspect(obj, opts);
return require('internal/util/inspect').inspect(obj, opts);
}
}));
Object.defineProperties(TextDecoder.prototype, {
Expand Down

0 comments on commit bf2b57e

Please sign in to comment.