import express from "express";
import { Profile } from "$controllers/index.js";
import { checkPermission } from "$middlewares/index.js";

const router = express.Router();

router.get("/", checkPermission("profile:view"), Profile.ALL);
router.get("/:id", checkPermission("profile:view"), Profile.SINGLE);
router.post("/", checkPermission("profile:create"), Profile.CREATE);
router.put("/:id", checkPermission("profile:update"), Profile.UPDATE);
router.delete("/:id", checkPermission("profile:delete"), Profile.DELETE);

export default router;
