Open source CapCut alternative.
TypeScript
feat(site): sign out everywhere from account settings
David Le7f4ba2d0bb41
diff --git a/site/src/app/app/settings/SettingsShell.tsx b/site/src/app/app/settings/SettingsShell.tsxindex 3a7d2661..ca5732a3 100644--- a/site/src/app/app/settings/SettingsShell.tsx+++ b/site/src/app/app/settings/SettingsShell.tsx@@ -73,7 +73,17 @@ export function SettingsShell({ children }: { children: ReactNode }) {<buttontype="button"onClick={() => {- void authClient.signOut().then(() => router.push("/"));+ // Sign out everywhere: revoke every session for this user (so the Mac app signs out+ // too), then clear this browser's session and leave. signOut + redirect always run,+ // even if the revoke call fails, so the user is never stranded signed-in locally.+ void (async () => {+ try {+ await authClient.revokeSessions();+ } finally {+ await authClient.signOut();+ router.push("/");+ }+ })();}}className="ml-2 rounded-md px-3 py-1.5 text-sm font-medium text-muted-foreground hover:text-foreground">