mirror of
https://github.com/danbulant/discord.js
synced 2026-05-25 21:12:06 +00:00
actually build 3.2.2 changes whoops
This commit is contained in:
parent
5ef3adffb4
commit
064bbb169c
1 changed files with 5 additions and 5 deletions
|
|
@ -39,7 +39,7 @@ var Client = (function () {
|
|||
this.token = token;
|
||||
this.state = 0;
|
||||
this.websocket = null;
|
||||
this.events = new Map();
|
||||
this.events = {};
|
||||
this.user = null;
|
||||
this.alreadySentData = false;
|
||||
this.serverCreateListener = new Map();
|
||||
|
|
@ -82,12 +82,12 @@ var Client = (function () {
|
|||
}, {
|
||||
key: "on",
|
||||
value: function on(event, fn) {
|
||||
this.events.set(event, fn);
|
||||
this.events[event] = fn;
|
||||
}
|
||||
}, {
|
||||
key: "off",
|
||||
value: function off(event, fn) {
|
||||
this.events["delete"](event);
|
||||
value: function off(event) {
|
||||
this.events[event] = null;
|
||||
}
|
||||
}, {
|
||||
key: "keepAlive",
|
||||
|
|
@ -107,7 +107,7 @@ var Client = (function () {
|
|||
for (var arg in arguments) {
|
||||
args.push(arguments[arg]);
|
||||
}
|
||||
var evt = this.events.get(event);
|
||||
var evt = this.events[event];
|
||||
if (evt) {
|
||||
evt.apply(this, args.slice(1));
|
||||
}
|
||||
|
|
|
|||
Loading…
Reference in a new issue