Skip to content
Snippets Groups Projects
Commit 7dcff44d authored by scmoritz's avatar scmoritz
Browse files

bugfix

parent 6bbe36d5
No related branches found
No related tags found
No related merge requests found
......@@ -96,7 +96,10 @@ export function checkLogin() {
} else if (dt.getTime() > APISession.lastChecked + 5000) {
return m.request({
method: 'GET',
url: `${apiUrl}/sessions/${APISession.token}`,
url: `${apiUrl}/sessions/${APISession.id}`,
headers: {
Authorization: `Token ${APISession.token}`,
},
}).then((result) => {
const dt2 = new Date();
log('session is still valid!');
......@@ -119,6 +122,5 @@ export function checkLogin() {
}
export function isLoggedIn() {
checkLogin();
return APISession.authenticated;
}
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment