Fixed #105 and built

This commit is contained in:
abalabahaha
2015-12-24 02:25:20 -08:00
committed by Amish Shah
parent beb91913bb
commit 830cc64828
27 changed files with 4963 additions and 246 deletions

View File

@@ -294,19 +294,19 @@ export default class InternalClient {
} else {
var tk = this.tokenCacher.getToken(email, password);
if( tk ){
return new Promise((resolve, reject) => {
this.client.emit("debug", "bypassed direct API login, used cached token");
this.state = ConnectionState.LOGGED_IN;
this.token = tk;
this.email = email;
this.password = password;
this.client.emit("debug", "bypassed direct API login, used cached token");
this.state = ConnectionState.LOGGED_IN;
this.token = tk;
this.email = email;
this.password = password;
return this.getGateway()
.then(url => {
this.createWS(url);
return tk;
});
return this.getGateway()
.then(url => {
this.createWS(url);
return tk;
});
return Promise.resolve(tk);
}
}