ignore: cloud
This commit is contained in:
@@ -23,9 +23,10 @@ function CopyStatus() {
|
||||
const isLoggedIn = query(async () => {
|
||||
"use server"
|
||||
const actor = await getActor()
|
||||
console.log(actor)
|
||||
if (actor.type === "account") {
|
||||
const workspaces = await withActor(() => Account.workspaces())
|
||||
throw redirect("/" + workspaces[0].id)
|
||||
throw redirect(`/workspace/${workspaces[0].id}`)
|
||||
}
|
||||
return false
|
||||
}, "isLoggedIn")
|
||||
|
||||
@@ -42,11 +42,12 @@ const createCheckoutUrl = action(async (successUrl: string, cancelUrl: string) =
|
||||
return withActor(() => Billing.generateCheckoutUrl({ successUrl, cancelUrl }))
|
||||
}, "checkoutUrl")
|
||||
|
||||
//export const route = {
|
||||
// preload: () => listKeys(),
|
||||
//}
|
||||
const createPortalUrl = action(async (returnUrl: string) => {
|
||||
"use server"
|
||||
return withActor(() => Billing.generatePortalUrl({ returnUrl }))
|
||||
}, "portalUrl")
|
||||
|
||||
export default function () {
|
||||
export default function() {
|
||||
const actor = createAsync(() => getActor())
|
||||
|
||||
/////////////////
|
||||
Reference in New Issue
Block a user