fix: backend+frontend full audit - 15 bugs fixed across all files
This commit is contained in:
@@ -4,7 +4,7 @@ const Auth = {
|
||||
|
||||
token() { return localStorage.getItem(this.TK); },
|
||||
user() { try { return JSON.parse(localStorage.getItem(this.US)); } catch { return null; } },
|
||||
logged() { return !!this.token(); },
|
||||
logged() { return !!(this.token() && this.user()); },
|
||||
|
||||
async login(username, password) {
|
||||
const d = await API.post('/auth/login', { username, password });
|
||||
|
||||
Reference in New Issue
Block a user