add account switcher to loading screen

This commit is contained in:
MathMan05 2024-08-11 15:41:51 -05:00
parent 6ac1a4e904
commit ef2d228b70
6 changed files with 178 additions and 133 deletions

View file

@ -36,6 +36,9 @@ class Localuser {
errorBackoff = 0;
mfa_enabled;
constructor(userinfo) {
if (userinfo === -1) {
return;
}
this.token = userinfo.token;
this.userinfo = userinfo;
this.serverurls = this.userinfo.serverurls;
@ -104,7 +107,9 @@ class Localuser {
this.outoffocus();
this.guilds = [];
this.guildids = new Map();
this.ws.close(4001);
if (this.ws) {
this.ws.close(4001);
}
SnowFlake.clear();
User.clear();
}