Have deleted commented out static files handling.
This commit is contained in:
parent
e0feb2eddf
commit
2d6f74e692
@ -3,7 +3,6 @@ const path = require("path");
|
||||
const Koa = require("koa");
|
||||
const koaPug = require("koa-pug");
|
||||
const koaRouter = require("koa-router");
|
||||
// const koaServe = require("koa-static");
|
||||
const bodyParser = require("koa-body")({multipart: true});
|
||||
const mysql = require("mysql");
|
||||
const fetch = require("node-fetch");
|
||||
@ -157,8 +156,6 @@ module.exports = () => {
|
||||
await ctx.render('500');
|
||||
}
|
||||
})
|
||||
// .use(koaServe(path.join("static", "shared")))
|
||||
// .use(koaServe(path.join("static", "dwelling")))
|
||||
.use(dwelling_router.routes())
|
||||
.listen(config.dwelling.port, config.dwelling.host);
|
||||
|
||||
|
3
files.js
3
files.js
@ -5,7 +5,6 @@ const Koa = require("koa");
|
||||
const koaPug = require("koa-pug");
|
||||
const koaRouter = require("koa-router");
|
||||
const koaRange = require("koa-range");
|
||||
//const koaServe = require("koa-static");
|
||||
const FileType = require("file-type");
|
||||
|
||||
const config = require("./config");
|
||||
@ -139,8 +138,6 @@ module.exports = () => {
|
||||
app
|
||||
.use(koaRange)
|
||||
.use(radio_router.routes())
|
||||
// .use(koaServe(path.join("static", "shared")))
|
||||
// .use(koaServe(path.join("static", "files")))
|
||||
.on("error", err => { if (!err.code == ECONNRESET || !err.code == ENOENT) console.log(err.code); })
|
||||
.listen(config.files.port, config.files.host);
|
||||
|
||||
|
3
radio.js
3
radio.js
@ -4,7 +4,6 @@ const path = require("path");
|
||||
const Koa = require("koa");
|
||||
const koaPug = require("koa-pug");
|
||||
const koaRouter = require("koa-router");
|
||||
// const koaServe = require("koa-static");
|
||||
const fetch = require("node-fetch");
|
||||
|
||||
const config = require("./config");
|
||||
@ -54,8 +53,6 @@ module.exports = () => {
|
||||
|
||||
app.proxy = true;
|
||||
app
|
||||
// .use(koaServe(path.join("static", "shared")))
|
||||
// .use(koaServe(path.join("static", "radio")))
|
||||
.use(radio_router.routes())
|
||||
.listen(config.radio.port, config.radio.host);
|
||||
|
||||
|
Loading…
Reference in New Issue
Block a user