window.onload = async () => { if (!isNodeJS) { document.getElementById("mobile-css").removeAttribute("disabled"); } setTimeout(async () => { loginStatus = JSON.parse(await (await window.fetch("https://money-v1.equestria.dev/Authentication/Test/")).text()).status; if (loginStatus === 1) { if (isNodeJS) { console.info("Starting authentication procedure (Electron)"); const { ipcRenderer } = require('electron'); ipcRenderer.send("login"); } else { console.info("Starting authentication procedure (Mobile)"); location.href = "https://money-v1.equestria.dev/Authentication/Mobile/" } } else { console.info("Authenticated successfully"); await refresh(); } }, 1000) }