|
@ -1,17 +1,13 @@ |
|
|
const routes = require('express').Router(); |
|
|
const routes = require('express').Router(); |
|
|
|
|
|
|
|
|
|
|
|
|
|
|
const api = require('./api'); |
|
|
const api = require('./api'); |
|
|
routes.use('/api', api); |
|
|
routes.use('/api', api); |
|
|
|
|
|
|
|
|
routes.get("/", (request, result) => |
|
|
|
|
|
{ |
|
|
|
|
|
result.redirect("index.html"); |
|
|
|
|
|
|
|
|
routes.get("/", (request, response) => { |
|
|
|
|
|
response.redirect("index.html"); |
|
|
}); |
|
|
}); |
|
|
|
|
|
|
|
|
routes.get('*', (request, result) => |
|
|
|
|
|
{ |
|
|
|
|
|
result.redirect("404.html"); |
|
|
|
|
|
|
|
|
routes.get('*', (request, response) => { |
|
|
|
|
|
response.redirect("404.html"); |
|
|
}); |
|
|
}); |
|
|
|
|
|
|
|
|
module.exports = routes; |
|
|
module.exports = routes; |