Skip to content

Commit

Permalink
fixed name of function returned by middlware
Browse files Browse the repository at this point in the history
  • Loading branch information
yasuaki640 committed Jul 22, 2024
1 parent b2d68e7 commit b21744f
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion src/middleware/csrf/index.ts
Original file line number Diff line number Diff line change
Expand Up @@ -73,7 +73,7 @@ export const csrf = (options?: CSRFOptions): MiddlewareHandler => {
return handler(origin, c)
}

return async function cors(c, next) {
return async function csrf(c, next) {
if (
!isSafeMethodRe.test(c.req.method) &&
isRequestedByFormElementRe.test(c.req.header('content-type') || '') &&
Expand Down

0 comments on commit b21744f

Please sign in to comment.