diff options
author | AlTech98 <altech123159@gmail.com> | 2021-09-18 10:44:25 +0200 |
---|---|---|
committer | AlTech98 <altech123159@gmail.com> | 2021-09-18 10:44:25 +0200 |
commit | 296375c67e388e08b09a9bda16348103df48b75c (patch) | |
tree | ee9ea44b98735ad830bfa7676234a18221542c3b /gateway/src | |
parent | Merge branch 'fosscord:master' into fix-dm (diff) | |
download | server-296375c67e388e08b09a9bda16348103df48b75c.tar.xz |
Fix gateway not listening for new channels events
Diffstat (limited to 'gateway/src')
-rw-r--r-- | gateway/src/listener/listener.ts | 11 |
1 files changed, 3 insertions, 8 deletions
diff --git a/gateway/src/listener/listener.ts b/gateway/src/listener/listener.ts index 16803639..35841312 100644 --- a/gateway/src/listener/listener.ts +++ b/gateway/src/listener/listener.ts @@ -116,7 +116,7 @@ async function consume(this: WebSocket, opts: EventOpts) { .has("VIEW_CHANNEL") ) return; - break; + //No break needed here, we need to call the listenEvent function below case "GUILD_CREATE": this.events[id] = await listenEvent(id, consumer, listenOpts); break; @@ -193,16 +193,11 @@ async function consume(this: WebSocket, opts: EventOpts) { break; } - let aa = { + Send(this, { op: OPCODES.Dispatch, t: event, d: data, s: this.sequence++, - } - - //TODO remove before PR merge - console.log(aa) - - Send(this, aa); + }); opts.acknowledge?.(); } |