Skip to content

⚡️⚡️⚡️ Self-hosted collaborative bookmark manager to collect, read, annotate, and fully preserve what matters, all in one place.

322 B
Raw Blame
import { prisma } from "@linkwarden/prisma";

export default async function getLinkHighlights({
  userId,
  linkId,
}: {
  userId: number;
  linkId: number;
}) {
  const highlights = await prisma.highlight.findMany({
    where: {
      linkId,
      userId,
    },
  });

  return { response: highlights, status: 200 };
}