docs(plugins): correct misleading secret-purge orphan comment

The uninstall purge comment claimed orphaned credentials are cleared
'until a later purge', but no reconcile exists: once the plugin is gone
from the registry, removeSecretsForPlugin/clearOAuthTokens are never
re-triggered for it. On an IndexedDB failure the secret/token orphans on
disk until the same plugin id is reinstalled and removed again. Reword
the comment to state this honestly.

Reported by @sbomsdorf in review of #8633.
This commit is contained in:
Johannes Millan 2026-06-30 13:39:59 +02:00
parent ba2f77804b
commit ff68fab0aa

View file

@ -1639,8 +1639,9 @@ export class PluginService implements OnDestroy {
// Purge local-only credentials (secrets + OAuth tokens) FIRST so they
// never outlive their plugin — even if a later cleanup step throws.
// Best-effort: a purge failure is logged but must not abort the uninstall
// (on IndexedDB failure the credentials orphan locally until a later purge).
// Best-effort: a purge failure is logged but must not abort the uninstall.
// There is no later reconcile, so on IndexedDB failure the credentials
// orphan on disk until the same plugin id is reinstalled and removed again.
try {
await this._pluginSecretService.removeSecretsForPlugin(pluginId);
} catch (error) {