mirror of
https://github.com/documenso/documenso.git
synced 2025-11-10 04:22:32 +10:00
16 lines
316 B
TypeScript
16 lines
316 B
TypeScript
'use server';
|
|
|
|
import { prisma } from '@documenso/prisma';
|
|
|
|
export type GetSubscriptionsByUserIdOptions = {
|
|
userId: string;
|
|
};
|
|
|
|
export const getSubscriptionsByUserId = async ({ userId }: GetSubscriptionsByUserIdOptions) => {
|
|
return await prisma.subscription.findMany({
|
|
where: {
|
|
userId,
|
|
},
|
|
});
|
|
};
|