fix login

This is a fixup commit to b2c800e654.
This commit is contained in:
Johann150 2022-11-08 21:59:13 +01:00
parent 54075789cd
commit 2496b385ce
Signed by untrusted user: Johann150
GPG key ID: 9EE6577A2A06F8F1

View file

@ -75,8 +75,7 @@ export async function removeAccount(id: Account['id']) {
function fetchAccount(token: string): Promise<Account> {
return new Promise((done, fail) => {
// Fetch user
api('i')
.then(res => res.json())
api('i', {}, token)
.then(res => {
if (res.error) {
if (res.error.id === 'a8c724b3-6e9c-4b46-b1a8-bc3ed6258370') {