File tree Expand file tree Collapse file tree 1 file changed +6
-6
lines changed
Expand file tree Collapse file tree 1 file changed +6
-6
lines changed Original file line number Diff line number Diff line change @@ -40,6 +40,11 @@ class Executor {
4040 let resolveFunction : ( ) => void ;
4141
4242 process . on ( 'close' , async ( code , signal ) => {
43+ const errorString = errors . join ( '\n' )
44+ if ( errorString . includes ( 'Address already in use' ) ) {
45+ return reject ( 'Port is already in use' )
46+ }
47+
4348 try {
4449 await fsPromises . rm ( dbPath , { recursive : true , force : true } )
4550 if ( binaryFilepath . includes ( os . tmpdir ( ) ) && ! options . downloadBinaryOnce ) {
@@ -60,13 +65,8 @@ class Executor {
6065 return reject ( 'Database exited early' )
6166 }
6267
63- const errorString = errors . join ( '\n' )
64- this . logger . error ( errorString )
65- if ( errorString . includes ( 'Address already in use' ) ) {
66- return reject ( 'Port is already in use' )
67- }
68-
6968 if ( code ) {
69+ this . logger . error ( errorString )
7070 return reject ( errorString )
7171 }
7272 }
You can’t perform that action at this time.
0 commit comments