diff options
| author | MaheshtheDev <[email protected]> | 2025-10-27 20:38:45 +0000 |
|---|---|---|
| committer | MaheshtheDev <[email protected]> | 2025-10-27 20:38:45 +0000 |
| commit | 6a47cd97636d243bd52adb69e9731ff1871ff212 (patch) | |
| tree | 6fea2fcbe8a61cfc894815880415fb39b0d2a27e /packages | |
| parent | feat: withSupermemory for openai sdk (#531) (diff) | |
| download | supermemory-6a47cd97636d243bd52adb69e9731ff1871ff212.tar.xz supermemory-6a47cd97636d243bd52adb69e9731ff1871ff212.zip | |
chore: skip the conditional org switch for better auth state share (#533)
Diffstat (limited to 'packages')
| -rw-r--r-- | packages/lib/auth-context.tsx | 17 |
1 files changed, 9 insertions, 8 deletions
diff --git a/packages/lib/auth-context.tsx b/packages/lib/auth-context.tsx index a8a296c7..7e6462fa 100644 --- a/packages/lib/auth-context.tsx +++ b/packages/lib/auth-context.tsx @@ -39,14 +39,15 @@ export function AuthProvider({ children }: { children: ReactNode }) { useEffect(() => { if (session?.session.activeOrganizationId) { authClient.organization.getFullOrganization().then((org) => { - if (org.metadata?.isConsumer === true) { - setOrg(org) - } else { - const consumerOrg = orgs?.find((o) => o.metadata?.isConsumer === true) - if (consumerOrg) { - setActiveOrg(consumerOrg.slug) - } - } + // TODO: Uncomment this when we have a way to handle consumer organizations better way + //if (org.metadata?.isConsumer === true) { + setOrg(org) + //} else { + // const consumerOrg = orgs?.find((o) => o.metadata?.isConsumer === true) + // if (consumerOrg) { + // setActiveOrg(consumerOrg.slug) + // } + //} }) } }, [session?.session.activeOrganizationId, orgs]) |