fix: update handleSwitchWorkspace signature to accept null
This commit is contained in:
@@ -22,7 +22,8 @@ export default function LayoutContent({ children }: { children: React.ReactNode
|
|||||||
}
|
}
|
||||||
}, [auth.user])
|
}, [auth.user])
|
||||||
|
|
||||||
const handleSwitchWorkspace = async (orgId: string) => {
|
const handleSwitchWorkspace = async (orgId: string | null) => {
|
||||||
|
if (!orgId) return // Pulse doesn't support personal workspace
|
||||||
try {
|
try {
|
||||||
const { access_token } = await switchContext(orgId)
|
const { access_token } = await switchContext(orgId)
|
||||||
await setSessionAction(access_token)
|
await setSessionAction(access_token)
|
||||||
|
|||||||
Reference in New Issue
Block a user