Repository navigation
Conversation
ramiresviana
left a comment
There was a problem hiding this comment.
Since the logout is happening without user interaction, adding a message to inform the user they’ve been logged out would make the behavior clearer. Also, please ensure the code passes linter checks by running pnpm run lint to avoid errors when this PR is merged.
Perfect, I made that change and I had no problems with |
ramiresviana
left a comment
There was a problem hiding this comment.
You have to fix the lint warnings
frontend > pnpm run lint
> [email protected] lint /home/filebrowser/frontend
> eslint src/
/home/filebrowser/frontend/src/types/user.d.ts
66:40 warning Insert `⏎` prettier/prettier
/home/filebrowser/frontend/src/utils/auth.ts
27:14 warning Replace `'inactivity'` with `"inactivity"` prettier/prettier
116:7 warning Insert `·` prettier/prettier
117:20 warning Delete `·` prettier/prettier
118:24 warning Delete `·` prettier/prettier
119:43 warning Insert `,` prettier/prettier
122:20 warning Delete `·` prettier/prettier
125:6 warning Delete `⏎····` prettier/prettier
/home/filebrowser/frontend/src/views/Login.vue
6:55 warning Replace `{{t(`login.logout_reasons.${reason}`)}}` with `⏎········{{·t(`login.logout_reasons.${reason}`)·}}⏎······` prettier/prettier
74:28 warning Replace `'logout-reason'` with `"logout-reason"` prettier/prettier
130:10 warning Insert `⏎` prettier/prettier
✖ 11 problems (0 errors, 11 warnings)
0 errors and 11 warnings potentially fixable with the `--fix` option.
…res' of https://github.com/ArielLeyva/filebrowser into fix/filebrowser#5212-show-login-when-session-token-expires
Code has been reformatted to comply with Prettier's guidelines. |
…th with custom logout is used
…th with custom logout is used
Closes #5212
Description
Implements automatic frontend redirection to the login page when the authentication token expires, based on the backend’s token-expiration-time setting.
Checklist
Before submitting your PR, please indicate which issues are either fixed or closed by this PR. See GitHub Help: Closing issues using keywords.
masterbranch.