fix: avoid Convex skip sentinel in queries

This commit is contained in:
Esdras Renan 2025-11-01 02:09:16 -03:00
parent 3880ff57bd
commit 3de7eccaa8
32 changed files with 131 additions and 125 deletions

View file

@ -37,8 +37,8 @@ export function SlasManager() {
const tenantId = session?.user.tenantId ?? DEFAULT_TENANT_ID
const slas = useQuery(
api.slas.list,
convexUserId ? { tenantId, viewerId: convexUserId as Id<"users"> } : "skip"
convexUserId ? api.slas.list : undefined,
convexUserId ? { tenantId, viewerId: convexUserId as Id<"users"> } : undefined
) as SlaPolicy[] | undefined
const createSla = useMutation(api.slas.create)