mirror of
https://github.com/aaronpo97/the-biergarten-app.git
synced 2026-02-16 18:52:06 +00:00
Fix beer likes and db client
This commit is contained in:
@@ -1,6 +1,11 @@
|
||||
import DBClient from '@/prisma/DBClient';
|
||||
|
||||
const findBeerPostLikeById = async (id: string) =>
|
||||
DBClient.instance.beerPostLike.findUnique({ where: { id } });
|
||||
const findBeerPostLikeById = async (beerPostId: string, userId: string) =>
|
||||
DBClient.instance.beerPostLike.findFirst({
|
||||
where: {
|
||||
beerPostId,
|
||||
userId,
|
||||
},
|
||||
});
|
||||
|
||||
export default findBeerPostLikeById;
|
||||
|
||||
Reference in New Issue
Block a user