mirror of
https://github.com/danbulant/discord.js
synced 2026-07-07 12:11:11 +00:00
Fix removeListener call (#762)
This commit is contained in:
parent
34168eb832
commit
1fcc618532
1 changed files with 2 additions and 2 deletions
|
|
@ -101,8 +101,8 @@ class MessageCollector extends EventEmitter {
|
||||||
get next() {
|
get next() {
|
||||||
return new Promise((resolve, reject) => {
|
return new Promise((resolve, reject) => {
|
||||||
const cleanup = () => {
|
const cleanup = () => {
|
||||||
this.removeListener(onMessage);
|
this.removeListener('message', onMessage);
|
||||||
this.removeListener(onEnd);
|
this.removeListener('end', onEnd);
|
||||||
};
|
};
|
||||||
|
|
||||||
const onMessage = (...args) => {
|
const onMessage = (...args) => {
|
||||||
|
|
|
||||||
Loading…
Reference in a new issue