Skip to content

Commit

Permalink
Add missing jwt check to game route
Browse files Browse the repository at this point in the history
  • Loading branch information
jrandiny committed Feb 25, 2021
1 parent 9476a2f commit a560f31
Showing 1 changed file with 2 additions and 0 deletions.
2 changes: 2 additions & 0 deletions src/routes/game.ts
Original file line number Diff line number Diff line change
Expand Up @@ -29,6 +29,8 @@ export default () => {
const typeCheck = () => check("type").isInt({ min: 1, max: 2 }).withMessage("must be valid type, 1 for quiz, 2 for crossword");
const difficultyCheck = () => check("difficulty").isInt({ min: 1 }).withMessage("must be valid difficulty");

router.use("/game", checkJWT);

router.get("/game",
limitAccess([UserRole.ADMIN]),
gc.listGame.bind(gc));
Expand Down

0 comments on commit a560f31

Please sign in to comment.