2022-08-28 06:38:35 +02:00
|
|
|
import prisma from 'lib/prisma';
|
2022-07-12 23:14:36 +02:00
|
|
|
|
2022-10-10 22:42:18 +02:00
|
|
|
export async function getUserWebsites(userId) {
|
2022-08-28 06:38:35 +02:00
|
|
|
return prisma.client.website.findMany({
|
|
|
|
where: {
|
2022-10-10 22:42:18 +02:00
|
|
|
userId,
|
2022-08-28 06:38:35 +02:00
|
|
|
},
|
|
|
|
orderBy: {
|
|
|
|
name: 'asc',
|
|
|
|
},
|
|
|
|
});
|
2022-07-12 23:14:36 +02:00
|
|
|
}
|