Skip to content

Add cors to routes #38

@raduorleanu

Description

@raduorleanu
  • App.ts options add app.options("*", cors());

  • Change routes everywhere to have [cors(), checkJwt]. cors() must be first, checkJwt must be second

  • Send token as object instead of string in authController

  • Set token to longer expiration (24 hours)

  • User controller have to return JSON not string:
    For example: "message": "username already in use"

Metadata

Metadata

Assignees

Labels

enhancementNew feature or request

Projects

No projects

Milestone

No milestone

Relationships

None yet

Development

No branches or pull requests

Issue actions