Add routes for getting disciplines

+ Throwing an error still crashes the server
This commit is contained in:
Stephan
2022-04-29 10:35:38 +02:00
parent df9b47dbfd
commit 3c8cea8c71
3 changed files with 115 additions and 1 deletions
+9
View File
@@ -0,0 +1,9 @@
import express from "express";
import { getAllDisciplines, getDiscipline } from "../Controllers/discipline.controller";
const router = express.Router();
router.get("/", getAllDisciplines); // TODO: Optional auth
router.get("/:pid", getDiscipline);
export default router;