-
-
Notifications
You must be signed in to change notification settings - Fork 5.8k
Improve logout from worker #30775
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Improve logout from worker #30775
Conversation
What I don't quite understand: Why do we have this |
Ah, so it's a multi-tab logout feature, ok. It does seem incorrect to listen for the event twice in both SSE subscriptions, but I guess this whole SSE code is very badly designed and needs a replacement, ideally websocket. |
Can confirm it works. Logged out on tab 1, 5 seconds later tab 2 logged out. Maybe the delay is a bit much though. |
It isn't much. Even if there is no logout from the worker, the user is indeed logged out, any new click will just request the page without signed-in account. |
A quick fix for go-gitea#30756
Backport #30775 by wxiaoguang A quick fix for #30756 Co-authored-by: wxiaoguang <[email protected]>
A quick fix for #30756