Add signup trial que crea tenant y owner
Co-Authored-By: Claude Sonnet 4.6 <noreply@anthropic.com>
This commit is contained in:
@@ -45,3 +45,8 @@ export async function createTenantWithOwner(input: {
|
||||
|
||||
return { tenant, user };
|
||||
}
|
||||
|
||||
export async function slugDisponible(slug: string): Promise<boolean> {
|
||||
const [row] = await db.select({ id: tenants.id }).from(tenants).where(eq(tenants.slug, slug)).limit(1);
|
||||
return !row;
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user