removed obsolete remember me button, added notification when trying to go down a protected route
This commit is contained in:
@@ -47,7 +47,7 @@ export const useUser = defineStore({
|
||||
},
|
||||
|
||||
actions: {
|
||||
async login(username: string, password: string, rememberMe: boolean): Promise<boolean> {
|
||||
async login(username: string, password: string): Promise<boolean> {
|
||||
|
||||
const notifications = useNotifications()
|
||||
|
||||
@@ -71,7 +71,7 @@ export const useUser = defineStore({
|
||||
if (axios.isAxiosError(err) && err.response && err.response.data){
|
||||
|
||||
const data = err.response.data as AuthErrResult
|
||||
|
||||
|
||||
notifications.add(data.notification.type, data.notification.text)
|
||||
|
||||
}
|
||||
@@ -116,7 +116,7 @@ export const useUser = defineStore({
|
||||
enabled: true,
|
||||
strategies: [
|
||||
{
|
||||
storage: localStorage
|
||||
storage: sessionStorage
|
||||
}
|
||||
]
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user