mirror of
https://github.com/firefly-iii/firefly-iii.git
synced 2025-02-25 18:45:27 -06:00
Redirect when unauthenticated.
This commit is contained in:
parent
b91e019416
commit
9c4beab0a7
@ -72,6 +72,13 @@ export default defineComponent(
|
||||
}).catch((err) => {
|
||||
console.error('Could not load preferences.');
|
||||
console.log(err);
|
||||
|
||||
// redirect user if 401
|
||||
if (err.response) {
|
||||
if(401 === err.response.status) {
|
||||
window.location.href = '/login';
|
||||
}
|
||||
}
|
||||
});
|
||||
};
|
||||
|
||||
|
Loading…
Reference in New Issue
Block a user