// routes/taskRoutes.js
const express = require('express');
const router = express.Router();
const taskController = require('../controllers/taskController');

// CREATE
router.post('/', taskController.createTask);

// READ ALL
router.get('/', taskController.getAllTasks);

// READ ONE
router.get('/:task_id', taskController.getTaskById);

// UPDATE
router.put('/:task_id', taskController.updateTask);

// DELETE
router.delete('/:task_id', taskController.removeTask);

module.exports = router;