const express = require("express");
const router = express.Router();

const { requireLogin } = require("../middleware/auth.middleware");
const {
  listMedications,
  updateMedication
} = require("../controllers/medication.controller");

router.get("/", requireLogin, listMedications);

// 🆕 UPDATE pro Zeile
router.post("/update/:id", requireLogin, updateMedication);

module.exports = router;
