Skip to content

Commit

Permalink
remove todos
Browse files Browse the repository at this point in the history
  • Loading branch information
psibean committed May 1, 2024
1 parent dad33c6 commit bb9bc42
Showing 1 changed file with 0 additions and 2 deletions.
2 changes: 0 additions & 2 deletions src/index.ts
Original file line number Diff line number Diff line change
Expand Up @@ -101,7 +101,6 @@ export function doubleCsrf({
// This should be used in routes or middleware to provide users with a token.
// The value returned from this should ONLY be sent to the client via a response payload.
// Do NOT send the csrfToken as a cookie, embed it in your HTML response, or as JSON.
// TODO: next major update, breaking change, combine extra params as a single object parameter
const generateToken: CsrfTokenCreator = (
req: Request,
res: Response,
Expand Down Expand Up @@ -172,7 +171,6 @@ export function doubleCsrf({
};

const doubleCsrfProtection: doubleCsrfProtection = (req, res, next) => {
// TODO: next major update, breaking change, make a single object parameter
req.csrfToken = (options: GenerateCsrfTokenOptions) =>
generateToken(req, res, options);
if (ignoredMethodsSet.has(req.method as RequestMethod)) {
Expand Down

0 comments on commit bb9bc42

Please sign in to comment.