Skip to content

Commit

Permalink
Stop duplicating ready/resume/disconnect events
Browse files Browse the repository at this point in the history
  • Loading branch information
abalabahaha committed Oct 19, 2017
1 parent c4b9c33 commit cdf2aaf
Showing 1 changed file with 3 additions and 3 deletions.
6 changes: 3 additions & 3 deletions lib/gateway/Shard.js
Expand Up @@ -110,7 +110,7 @@ class Shard extends EventEmitter {
* @event Shard#disconnect
* @prop {Error?} err The error, if any
*/
this.emit("disconnect", error || null);
super.emit("disconnect", error || null);
this.ws = null;

this.reset();
Expand Down Expand Up @@ -1174,7 +1174,7 @@ class Shard extends EventEmitter {
* @event Shard#resume
* @prop {Number} id The ID of the shard
*/
this.emit("resume");
super.emit("resume");
break;
}

Expand Down Expand Up @@ -1478,7 +1478,7 @@ class Shard extends EventEmitter {
* Fired when the shard turns ready
* @event Shard#ready
*/
this.emit("ready");
super.emit("ready");
}
}
}
Expand Down

0 comments on commit cdf2aaf

Please sign in to comment.