feat: Implement API and cache improvements

This commit is contained in:
gpt-engineer-app[bot]
2025-10-31 12:11:14 +00:00
parent 2fb983bb4f
commit 0d16bb511c
11 changed files with 584 additions and 9 deletions

View File

@@ -331,6 +331,26 @@ export function useQueryInvalidation() {
});
},
/**
* Invalidate email change status cache
* Call this after email change operations
*/
invalidateEmailChangeStatus: () => {
queryClient.invalidateQueries({
queryKey: queryKeys.security.emailChangeStatus()
});
},
/**
* Invalidate sessions cache
* Call this after session operations (login, logout, revoke)
*/
invalidateSessions: () => {
queryClient.invalidateQueries({
queryKey: queryKeys.security.sessions()
});
},
/**
* Invalidate security queries
* Call this after security-related changes (email, sessions)