consistent arrow functions

This commit is contained in:
jake committed 2025-03-12 18:10:11 -04:00
1 parent 6a57fde2f1
commit e61ca889a7
39 files changed
+121 -126

No files matched your search

+3 -3
View File
@@ -4,12 +4,12 @@ import type { hits as Hits } from "@prisma/client";
export const revalidate = 900; // 15 mins
export async function GET(): Promise<
export const GET = async (): Promise<
NextResponse<{
total: Pick<Hits, "hits">;
pages: Hits[];
}>
> {
> => {
// fetch all rows from db sorted by most hits
const pages = await prisma.hits.findMany({
orderBy: [
@@ -28,4 +28,4 @@ export async function GET(): Promise<
});
return NextResponse.json({ total, pages });
}
};