From 0ec1dd1aacdce1e85d6250db9b61a3edccfaafa7 Mon Sep 17 00:00:00 2001 From: Derrick Hammer Date: Sat, 22 Jul 2023 10:14:01 -0400 Subject: [PATCH] feat: add getListeners method to Socket --- src/index.ts | 4 ++++ 1 file changed, 4 insertions(+) diff --git a/src/index.ts b/src/index.ts index 9c6112d..bb152e7 100644 --- a/src/index.ts +++ b/src/index.ts @@ -253,6 +253,10 @@ export class Socket extends Client { ); } + async getListeners() { + return this.callModuleReturn("socketListeners", { id: this.id }); + } + private ensureEvent(event: string): void { if (!(event in this.eventUpdates)) { this.eventUpdates[event] = new Map();