mirror of
https://github.com/monkeytypegame/monkeytype.git
synced 2025-02-05 21:33:40 +08:00
added some console logs to debug the page changing issue
This commit is contained in:
parent
9611ca9b98
commit
372c8171b5
1 changed files with 7 additions and 0 deletions
|
@ -114,6 +114,9 @@ export function changePage(page) {
|
|||
let activePage = $(".page.active");
|
||||
$(".page").removeClass("active");
|
||||
$("#wordsInput").focusout();
|
||||
console.log(
|
||||
`changing to page ${page}, current active is ${activePage[0].classList}`
|
||||
);
|
||||
if (page == "test" || page == "") {
|
||||
setPageTransition(true);
|
||||
swapElements(
|
||||
|
@ -162,6 +165,9 @@ export function changePage(page) {
|
|||
SignOutButton.hide();
|
||||
} else if (page == "account") {
|
||||
if (!firebase.auth().currentUser) {
|
||||
console.log(
|
||||
`current user is ${firebase.auth().currentUser}, going back to login`
|
||||
);
|
||||
changePage("login");
|
||||
} else {
|
||||
setPageTransition(true);
|
||||
|
@ -199,6 +205,7 @@ export function changePage(page) {
|
|||
SignOutButton.hide();
|
||||
}
|
||||
}
|
||||
console.log("change page finished");
|
||||
}
|
||||
|
||||
if (firebase.app().options.projectId === "monkey-type-dev-67af4") {
|
||||
|
|
Loading…
Reference in a new issue