BREAKING refactor: detach request from handler context (#114)
This commit is contained in:
+1
-1
@@ -148,7 +148,7 @@ const JOKES = [
|
||||
"An SEO expert walked into a bar, pub, inn, tavern, hostelry, public house.",
|
||||
];
|
||||
|
||||
export const handler = (_ctx: HandlerContext): Response => {
|
||||
export const handler = (_req: Request, _ctx: HandlerContext): Response => {
|
||||
const randomIndex = Math.floor(Math.random() * 10);
|
||||
const body = JOKES[randomIndex];
|
||||
return new Response(body);
|
||||
|
||||
Reference in New Issue
Block a user