try to add image mapping
This commit is contained in:
parent
49904865eb
commit
8ed0fa5de2
7 changed files with 71 additions and 3 deletions
|
@ -1,7 +1,14 @@
|
|||
import { getServerSession } from "next-auth";
|
||||
import { getSession } from "next-auth/react";
|
||||
import prisma from "./prisma";
|
||||
|
||||
export const getBorderById = async (id) => {
|
||||
return await prisma.borderImage.findFirst({
|
||||
where: {
|
||||
id: parseInt(id)
|
||||
}
|
||||
});
|
||||
}
|
||||
|
||||
export const getUserBorders = async (req) => {
|
||||
const session = await getSession({ req });
|
||||
if (!session) {
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue