File tree 4 files changed +5
-6
lines changed
4 files changed +5
-6
lines changed Original file line number Diff line number Diff line change 1
1
'use strict' ;
2
2
3
3
const assert = require ( 'internal/assert' ) ;
4
- const util = require ( 'util' ) ;
5
4
const { Socket } = require ( 'net' ) ;
6
5
const { JSStream } = internalBinding ( 'js_stream' ) ;
7
6
const uv = internalBinding ( 'uv' ) ;
8
- const debug = util . debuglog ( 'stream_socket' ) ;
7
+ const debug = require ( 'internal/ util/debuglog' ) . debuglog ( 'stream_socket' ) ;
9
8
const { owner_symbol } = require ( 'internal/async_hooks' ) . symbols ;
10
9
const { ERR_STREAM_WRAP } = require ( 'internal/errors' ) . codes ;
11
10
Original file line number Diff line number Diff line change 1
1
'use strict' ;
2
2
3
3
const { Buffer } = require ( 'buffer' ) ;
4
- const { inspect } = require ( 'util' ) ;
4
+ const { inspect } = require ( 'internal/ util/inspect ' ) ;
5
5
6
6
function copyBuffer ( src , target , offset ) {
7
7
Buffer . prototype . copy . call ( src , target , offset ) ;
Original file line number Diff line number Diff line change 4
4
'use strict' ;
5
5
6
6
const stream = require ( 'stream' ) ;
7
- const util = require ( 'util' ) ;
8
7
9
8
const {
10
9
getDefaultEncoding
@@ -17,7 +16,8 @@ function LazyTransform(options) {
17
16
this . writable = true ;
18
17
this . readable = true ;
19
18
}
20
- util . inherits ( LazyTransform , stream . Transform ) ;
19
+ Object . setPrototypeOf ( LazyTransform . prototype , stream . Transform . prototype ) ;
20
+ Object . setPrototypeOf ( LazyTransform , stream . Transform ) ;
21
21
22
22
function makeGetter ( name ) {
23
23
return function ( ) {
Original file line number Diff line number Diff line change @@ -43,7 +43,7 @@ Stream.Stream = Stream;
43
43
44
44
// Internal utilities
45
45
try {
46
- const types = require ( 'util' ) . types ;
46
+ const types = require ( 'internal/ util/types' ) ;
47
47
if ( types && typeof types . isUint8Array === 'function' ) {
48
48
Stream . _isUint8Array = types . isUint8Array ;
49
49
} else {
You can’t perform that action at this time.
0 commit comments