multy-stub/server/routers/kfu-m-24-1/sberhubproject/index.js
2024-12-28 11:02:11 +03:00

17 lines
386 B
JavaScript

const router = require('express').Router();
const interestsRouter = require('./interests');
const usersRouter = require('./users');
module.exports = router;
const delay =
(ms = 1000) =>
(req, res, next) => {
setTimeout(next, ms);
};
router.use(delay());
router.use('/interests', interestsRouter);
router.use('/users', usersRouter);
router.use('/users/:id', usersRouter);