Moving files and rename some of them.

This commit is contained in:
charles-gauthereau
2024-12-16 16:30:00 +01:00
parent c97d68d697
commit 31ee81c10f
75 changed files with 64 additions and 175 deletions
@@ -0,0 +1,24 @@
"use server"
import {userAction} from "@/safe-actions";
import {z} from "zod";
import {prisma} from "@/prisma";
export const updateImageUserAction = userAction
.schema(z.string())
.action(async ({parsedInput, ctx}) => {
const user = await prisma.user.update({
where: {
id: ctx.user.id,
},
data: {
image: parsedInput,
}
})
return {
data: user,
}
});