1
0
Fork 0
mirror of https://github.com/jellyfin/jellyfin-web synced 2025-03-30 19:56:21 +00:00

Merge pull request #5500 from thornbill/fix-logout-credentials

Fix stored credentials not updating on logout
This commit is contained in:
Bill Thornton 2024-05-14 17:22:11 -04:00 committed by GitHub
commit ea8ceaa727
No known key found for this signature in database
GPG key ID: B5690EEEBB952194

View file

@ -35,6 +35,8 @@ class ServerConnections extends ConnectionManager {
Events.on(this, 'localusersignedout', (_e, logoutInfo) => {
setUserInfo(null, null);
// Ensure the updated credentials are persisted to storage
credentialProvider.credentials(credentialProvider.credentials());
if (window.NativeShell && typeof window.NativeShell.onLocalUserSignedOut === 'function') {
window.NativeShell.onLocalUserSignedOut(logoutInfo);
@ -128,12 +130,12 @@ class ServerConnections extends ConnectionManager {
}
}
const credentials = new Credentials();
const credentialProvider = new Credentials();
const capabilities = Dashboard.capabilities(appHost);
export default new ServerConnections(
credentials,
credentialProvider,
appHost.appName(),
appHost.appVersion(),
appHost.deviceName(),