File tree Expand file tree Collapse file tree 1 file changed +7
-6
lines changed Expand file tree Collapse file tree 1 file changed +7
-6
lines changed Original file line number Diff line number Diff line change @@ -76,11 +76,12 @@ function GetName(object) {
76
76
return desc && desc . value ;
77
77
}
78
78
79
- let util ;
80
- function lazyUtil ( ) {
81
- if ( ! util )
82
- util = require ( 'util' ) ;
83
- return util ;
79
+ let internalUtilInspect ;
80
+ function inspect ( ...args ) {
81
+ if ( ! internalUtilInspect ) {
82
+ internalUtilInspect = require ( 'internal/util/inspect' ) ;
83
+ }
84
+ return internalUtilInspect . inspect ( ...args ) ;
84
85
}
85
86
86
87
let serialize ;
@@ -107,7 +108,7 @@ function serializeError(error) {
107
108
return Buffer . concat ( [ Buffer . from ( [ kSerializedObject ] ) , serialized ] ) ;
108
109
} catch { }
109
110
return Buffer . concat ( [ Buffer . from ( [ kInspectedError ] ) ,
110
- Buffer . from ( lazyUtil ( ) . inspect ( error ) , 'utf8' ) ] ) ;
111
+ Buffer . from ( inspect ( error ) , 'utf8' ) ] ) ;
111
112
}
112
113
113
114
let deserialize ;
You can’t perform that action at this time.
0 commit comments