front/stubs/api/middlewares/delay.js

6 lines
102 B
JavaScript
Raw Permalink Normal View History

2024-09-28 12:51:59 +03:00
const delay = (ms = 1000) => (req, res, next) => {
setTimeout(next, ms)
}
module.exports = delay