diff options
| author | Frank <[email protected]> | 2025-10-16 23:43:49 -0400 |
|---|---|---|
| committer | Frank <[email protected]> | 2025-10-16 23:43:49 -0400 |
| commit | 5f7bba11fddd24f01c7be81870320dfe54672a3b (patch) | |
| tree | 213839ae793552f6ecc0bed6d999058381533428 /packages/console/app/src/context/auth.ts | |
| parent | 4663ea5faad41f8be9d16898f0d041630acf0c13 (diff) | |
| download | opencode-5f7bba11fddd24f01c7be81870320dfe54672a3b.tar.gz opencode-5f7bba11fddd24f01c7be81870320dfe54672a3b.zip | |
wip: zen
Diffstat (limited to 'packages/console/app/src/context/auth.ts')
| -rw-r--r-- | packages/console/app/src/context/auth.ts | 10 |
1 files changed, 8 insertions, 2 deletions
diff --git a/packages/console/app/src/context/auth.ts b/packages/console/app/src/context/auth.ts index c177049c3..dbbd3c3b2 100644 --- a/packages/console/app/src/context/auth.ts +++ b/packages/console/app/src/context/auth.ts @@ -1,5 +1,5 @@ import { getRequestEvent } from "solid-js/web" -import { and, Database, eq, inArray, sql } from "@opencode-ai/console-core/drizzle/index.js" +import { and, Database, eq, inArray, isNull, sql } from "@opencode-ai/console-core/drizzle/index.js" import { UserTable } from "@opencode-ai/console-core/schema/user.sql.js" import { redirect } from "@solidjs/router" import { Actor } from "@opencode-ai/console-core/actor.js" @@ -56,7 +56,13 @@ export const getActor = async (workspace?: string): Promise<Actor.Info> => { tx .select() .from(UserTable) - .where(and(eq(UserTable.workspaceID, workspace), inArray(UserTable.accountID, accounts))) + .where( + and( + eq(UserTable.workspaceID, workspace), + isNull(UserTable.timeDeleted), + inArray(UserTable.accountID, accounts), + ), + ) .limit(1) .execute() .then((x) => x[0]), |
