mirror of
https://github.com/monkeytypegame/monkeytype.git
synced 2024-09-21 15:56:24 +08:00
signing out when data download failed
This commit is contained in:
parent
4936fcadfd
commit
7fcdfb477d
|
@ -17,6 +17,7 @@ import * as Settings from "./settings";
|
|||
import * as ThemePicker from "./theme-picker";
|
||||
import * as AllTimeStats from "./all-time-stats";
|
||||
import * as PbTables from "./pb-tables";
|
||||
import * as AccountController from "./account-controller";
|
||||
import axiosInstance from "./axios-instance";
|
||||
|
||||
let filterDebug = false;
|
||||
|
@ -37,9 +38,10 @@ export async function getDataAndInit() {
|
|||
let msg = e?.response?.data?.message ?? e.message;
|
||||
Notifications.add("Failed to get user data: " + msg, -1);
|
||||
|
||||
$("#top #menu .account .icon").html('<i class="fas fa-fw fa-times"></i>');
|
||||
// $("#top #menu .account .icon").html('<i class="fas fa-fw fa-times"></i>');
|
||||
$("#top #menu .account").css("opacity", 1);
|
||||
if ($(".pageLoading").hasClass("active")) UI.changePage("");
|
||||
AccountController.signOut();
|
||||
return;
|
||||
}
|
||||
let snap = DB.getSnapshot();
|
||||
|
|
Loading…
Reference in a new issue