enzostvs HF staff commited on
Commit
615c1b6
β€’
1 Parent(s): d6da254

fixe my generations route

Browse files
src/routes/api/@me/generations/+server.ts CHANGED
@@ -26,7 +26,7 @@ export async function GET({ cookies } : RequestEvent) {
26
 
27
  const cards = await prisma.gallery.findMany({
28
  where: {
29
- hf_user_id: user.sub
30
  },
31
  orderBy: {
32
  createdAt: 'desc'
@@ -42,7 +42,7 @@ export async function GET({ cookies } : RequestEvent) {
42
 
43
  const total_reposId = await prisma.gallery.count({
44
  where: {
45
- hf_user_id: user.sub
46
  },
47
  })
48
 
 
26
 
27
  const cards = await prisma.gallery.findMany({
28
  where: {
29
+ userId: user.sub
30
  },
31
  orderBy: {
32
  createdAt: 'desc'
 
42
 
43
  const total_reposId = await prisma.gallery.count({
44
  where: {
45
+ userId: user.sub
46
  },
47
  })
48