mirror of
https://github.com/streamyfin/streamyfin.git
synced 2026-06-03 12:38:26 +01:00
refactor: remove unused clearAllCredentials and log diagnostics helpers
clearAllCredentials() (secureCredentials.ts), clearLogs() and dumpDownloadDiagnostics() (log.tsx) have no callers anywhere in the tree. Carried over from the original #1347 cleanup.
This commit is contained in:
@@ -203,27 +203,6 @@ export async function hasAccountCredential(
|
||||
return stored !== null;
|
||||
}
|
||||
|
||||
/**
|
||||
* Delete all credentials for all accounts on all servers.
|
||||
*/
|
||||
export async function clearAllCredentials(): Promise<void> {
|
||||
const previousServers = getPreviousServers();
|
||||
|
||||
for (const server of previousServers) {
|
||||
for (const account of server.accounts) {
|
||||
const key = credentialKey(server.address, account.userId);
|
||||
await SecureStore.deleteItemAsync(key);
|
||||
}
|
||||
}
|
||||
|
||||
// Clear all accounts from servers
|
||||
const clearedServers = previousServers.map((server) => ({
|
||||
...server,
|
||||
accounts: [],
|
||||
}));
|
||||
storage.set("previousServers", JSON.stringify(clearedServers));
|
||||
}
|
||||
|
||||
/**
|
||||
* Add or update an account in a server's accounts list.
|
||||
*/
|
||||
|
||||
Reference in New Issue
Block a user