import prisma from '../app/db.server.ts';

async function checkTypes() {
  const types = await prisma.notification.groupBy({
    by: ['type'],
    _count: { id: true },
  });
  console.log('Notification Types in DB:', types);

  const total = await prisma.notification.count();
  console.log('Total Notifications in DB:', total);

  const unread = await prisma.notification.count({ where: { isRead: false } });
  console.log('Unread Notifications in DB:', unread);
}

checkTypes()
  .catch(console.error)
  .finally(() => prisma.$disconnect());
