fix(auth): add remove() trap to engine auth storage proxy
The CLI proxy already had a remove() trap, but the engine's createFusionAuthStorage was missing it. Without this trap, calling remove() on a provider would delete the credential from storage but not add it to loggedOutProviders, allowing fallback credentials to resurrect the provider on the next read. Co-Authored-By: Claude Opus 4.6 <noreply@anthropic.com>
This commit is contained in:
@@ -183,6 +183,13 @@ export function createFusionAuthStorage(): AuthStorage {
|
||||
};
|
||||
}
|
||||
|
||||
if (prop === "remove") {
|
||||
return (provider: string) => {
|
||||
target.remove(provider);
|
||||
loggedOutProviders.add(provider);
|
||||
};
|
||||
}
|
||||
|
||||
if (prop === "set") {
|
||||
return (provider: string, credential: AuthCredential) => {
|
||||
target.set(provider, credential);
|
||||
|
||||
Reference in New Issue
Block a user