mirror of
https://github.com/Sendouc/sendou.ink.git
synced 2026-04-23 07:34:07 -05:00
13 lines
385 B
TypeScript
13 lines
385 B
TypeScript
import { NextApiRequest, NextApiResponse } from "next";
|
|
import { getAllSalmonRunRotations } from "prisma/queries/getAllSalmonRunRotations";
|
|
|
|
const rotationsHandler = async (req: NextApiRequest, res: NextApiResponse) => {
|
|
if (req.method !== "GET") {
|
|
return res.status(405).end();
|
|
}
|
|
|
|
res.status(200).json(await getAllSalmonRunRotations());
|
|
};
|
|
|
|
export default rotationsHandler;
|