const express = require('express');
const { protect } = require('./auth');

// Helper function to apply protect middleware to all routes in a router
const protectRoutes = (router) => {
  router.use(protect);
  return router;
};

module.exports = { protectRoutes };
