File tree 2 files changed +6
-6
lines changed
2 files changed +6
-6
lines changed Original file line number Diff line number Diff line change @@ -199,8 +199,8 @@ class NodeInspector {
199
199
process . once ( 'SIGTERM' , exitCodeZero ) ;
200
200
process . once ( 'SIGHUP' , exitCodeZero ) ;
201
201
202
- PromisePrototypeCatch ( PromisePrototypeThen ( this . run ( ) , ( ) => {
203
- const repl = startRepl ( ) ;
202
+ PromisePrototypeCatch ( PromisePrototypeThen ( this . run ( ) , async ( ) => {
203
+ const repl = await startRepl ( ) ;
204
204
this . repl = repl ;
205
205
this . repl . on ( 'exit' , exitCodeZero ) ;
206
206
this . paused = false ;
Original file line number Diff line number Diff line change @@ -1146,14 +1146,17 @@ function createRepl(inspector) {
1146
1146
return Runtime . runIfWaitingForDebugger ( ) ;
1147
1147
}
1148
1148
1149
- return function startRepl ( ) {
1149
+ return async function startRepl ( ) {
1150
1150
inspector . client . on ( 'close' , ( ) => {
1151
1151
resetOnStart ( ) ;
1152
1152
} ) ;
1153
1153
inspector . client . on ( 'ready' , ( ) => {
1154
1154
initAfterStart ( ) ;
1155
1155
} ) ;
1156
1156
1157
+ // Init once for the initial connection
1158
+ await initAfterStart ( ) ;
1159
+
1157
1160
const replOptions = {
1158
1161
prompt : 'debug> ' ,
1159
1162
input : inspector . stdin ,
@@ -1172,9 +1175,6 @@ function createRepl(inspector) {
1172
1175
repl . emit ( 'SIGINT' ) ;
1173
1176
} ) ;
1174
1177
1175
- // Init once for the initial connection
1176
- initAfterStart ( ) ;
1177
-
1178
1178
return repl ;
1179
1179
} ;
1180
1180
}
You can’t perform that action at this time.
0 commit comments