mirror of
https://github.com/Bubka/2FAuth.git
synced 2025-08-14 15:58:36 +02:00
Enable the Vue 3 front-end
This commit is contained in:
9
resources/js/router/middlewares/noEmptyError.js
vendored
Normal file
9
resources/js/router/middlewares/noEmptyError.js
vendored
Normal file
@ -0,0 +1,9 @@
|
||||
export default function noEmptyError({ to, next, nextMiddleware, stores }) {
|
||||
const { notify } = stores
|
||||
|
||||
if (notify.err == null) {
|
||||
// return to home if no err object is set to prevent an empty error message
|
||||
next({ name: 'accounts' });
|
||||
}
|
||||
else nextMiddleware()
|
||||
}
|
Reference in New Issue
Block a user