mirror of
https://github.com/discordjs/discord.js.git
synced 2026-03-15 11:03:30 +01:00
minor bug fixes
This commit is contained in:
4
index.js
4
index.js
@@ -52,7 +52,7 @@ exports.Client.prototype.getChannel = function( id ) {
|
|||||||
|
|
||||||
exports.Client.prototype.triggerEvent = function( event, args ) {
|
exports.Client.prototype.triggerEvent = function( event, args ) {
|
||||||
|
|
||||||
if ( !this.ready && event !== "raw" && event !== "disconnected" ) { //if we're not even loaded yet, don't try doing anything because it always ends badly!
|
if ( !this.ready && event !== "raw" && event !== "disconnected" && event !== "debug" ) { //if we're not even loaded yet, don't try doing anything because it always ends badly!
|
||||||
return;
|
return;
|
||||||
}
|
}
|
||||||
|
|
||||||
@@ -364,6 +364,8 @@ exports.Client.prototype.connectWebsocket = function( cb ) {
|
|||||||
|
|
||||||
exports.Client.prototype.logout = function( callback ) {
|
exports.Client.prototype.logout = function( callback ) {
|
||||||
|
|
||||||
|
callback = callback || function(){};
|
||||||
|
|
||||||
var self = this;
|
var self = this;
|
||||||
|
|
||||||
Internal.XHR.logout( self.token, function( err ) {
|
Internal.XHR.logout( self.token, function( err ) {
|
||||||
|
|||||||
Reference in New Issue
Block a user