File tree 1 file changed +4
-2
lines changed 1 file changed +4
-2
lines changed Original file line number Diff line number Diff line change @@ -282,7 +282,8 @@ class WebSocket extends EventEmitter {
282
282
if ( this . readyState === WebSocket . CLOSED ) return ;
283
283
if ( this . readyState === WebSocket . CONNECTING ) {
284
284
const msg = 'WebSocket was closed before the connection was established' ;
285
- return abortHandshake ( this , this . _req , msg ) ;
285
+ abortHandshake ( this , this . _req , msg ) ;
286
+ return ;
286
287
}
287
288
288
289
if ( this . readyState === WebSocket . CLOSING ) {
@@ -477,7 +478,8 @@ class WebSocket extends EventEmitter {
477
478
if ( this . readyState === WebSocket . CLOSED ) return ;
478
479
if ( this . readyState === WebSocket . CONNECTING ) {
479
480
const msg = 'WebSocket was closed before the connection was established' ;
480
- return abortHandshake ( this , this . _req , msg ) ;
481
+ abortHandshake ( this , this . _req , msg ) ;
482
+ return ;
481
483
}
482
484
483
485
if ( this . _socket ) {
You can’t perform that action at this time.
0 commit comments