Rallly is an open-source scheduling and collaboration tool designed to make organizing events and meetings easier.
TypeScript i18nextnext-authnextjspostgresqlprismareact-emailt3-stacktailwindcsstrpcturborepotypescriptzod
import "server-only";
import { prisma } from "@rallly/database";
import type { AuthorizedSpaceId } from "@/features/space/types";
export async function getNonprofitDiscountGrantedAt(
spaceId: AuthorizedSpaceId,
) {
const space = await prisma.space.findUnique({
where: { id: spaceId },
select: { nonprofitDiscountGrantedAt: true },
});
return space?.nonprofitDiscountGrantedAt ?? null;
}