Andrey Ivlev 552457b5cb
All checks were successful
platform/multy-stub/pipeline/head This commit looks good
feature(freetracker): landing requests
2025-01-18 20:28:22 +03:00

29 lines
491 B
JavaScript

const Router = require('express').Router;
const router = Router()
const values = {
'blocks': 'success',
'application': 'success'
}
const timer = (_req, _res, next) => {
setTimeout(() => next(), 500)
}
router.use(timer)
router.get(
'/blocks',
(req, res) =>
res.send(require(`./json/blocks-${values['blocks']}.json`))
)
router.post(
'/application',
(req, res) => {
res.send(require(`./json/application-${values['application']}.json`))
}
)
module.exports = router