From f7d59b48c1ee9a07515b032b60fd0388095d4dfb Mon Sep 17 00:00:00 2001 From: tiagosiebler Date: Mon, 19 Sep 2022 00:18:56 +0100 Subject: [PATCH] fix mistake --- test/ws.util.ts | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) diff --git a/test/ws.util.ts b/test/ws.util.ts index 7d1423e..a20793b 100644 --- a/test/ws.util.ts +++ b/test/ws.util.ts @@ -59,7 +59,7 @@ export function waitForSocketEvent( } wsClient.on(event, (e) => resolver(e)); - wsClient.on('errorEvent', (e) => rejector(e)); + wsClient.on('error', (e) => rejector(e)); // if (event !== 'close') { // wsClient.on('close', (event) => { @@ -89,7 +89,7 @@ export function listenToSocketEvents(wsClient: WebsocketClient) { wsClient.on('response', retVal.response); wsClient.on('update', retVal.update); wsClient.on('close', retVal.close); - wsClient.on('errorEvent', retVal.error); + wsClient.on('error', retVal.error); return { ...retVal, @@ -98,7 +98,7 @@ export function listenToSocketEvents(wsClient: WebsocketClient) { wsClient.removeListener('response', retVal.response); wsClient.removeListener('update', retVal.update); wsClient.removeListener('close', retVal.close); - wsClient.removeListener('errorEvent', retVal.error); + wsClient.removeListener('error', retVal.error); }, }; }