fix: use new API route style in fresh init (#54)

This commit is contained in:
Luca Casonato
2021-09-25 11:01:11 +02:00
committed by GitHub
parent f5b3faf0d8
commit f44f1950dc
+1 -1
View File
@@ -128,7 +128,7 @@ const JOKES = [
"An SEO expert walked into a bar, pub, inn, tavern, hostelry, public house.",
];
export default (_req: Request): Response => {
export const handler = (_req: Request): Response => {
const randomIndex = Math.floor(Math.random() * 10);
const body = JOKES[randomIndex];
return new Response(body);