Michal KváčekandClaude Sonnet 5 3f8ef6b985 Fix access token refresh for mutations, add login overlay fallback
Mutations never triggered the token-refresh path — only query() set the
_refreshUnauthorizedUser flag apollo.js's errorLink checks, so a 401 on a
mutation silently dropped the change instead of retrying. handleRefreshToken
also had a latent bug (.then(value => value.flatMap(...)) on a string access
token), which would have thrown even for queries.

Changes:
- stores/helpers.js: mutate() now sets _refreshUnauthorizedUser like query()
  does.
- boot/apollo.js: fix the flatMap bug; when the token refresh call itself
  fails, show a persistent, non-dismissible login overlay instead of
  navigating to /login (which would discard in-progress form state), then
  retry the exact same query/mutation after successful login. Dedup
  concurrent failures behind one shared overlay/promise. Add a loop guard
  so a retried operation that 401s again fails cleanly instead of retrying
  forever. mutateImpl no longer swallows errors into a fake success.
- stores/Auth.js: dedupe concurrent refreshAccessToken() calls via an
  in-flight promise.
- components/auth/LoginOverlayDialog.vue: new persistent login dialog used
  by the overlay fallback above.

Co-Authored-By: Claude Sonnet 5 <noreply@anthropic.com>
2026-09-14 13:23:31 +02:00
2024-04-15 18:13:22 +02:00
2023-05-31 20:44:10 +02:00
2023-05-31 20:44:10 +02:00
2023-05-31 20:44:10 +02:00
2025-03-05 13:23:56 +01:00
2023-05-31 20:44:10 +02:00
2023-08-29 21:28:29 +02:00
2024-05-09 13:17:44 +02:00
2024-05-09 13:31:50 +02:00
2023-05-31 20:44:10 +02:00
2026-09-14 11:08:22 +02:00
2026-09-14 11:08:22 +02:00
S
Description
No description provided
Readme
12 MiB
Languages
Vue 73.4%
JavaScript 25.7%
HTML 0.4%
SCSS 0.2%
Dockerfile 0.2%
Other 0.1%