Removed serving of auth pages from lib/members
no-issue
This commit is contained in:
parent
bf156b0b79
commit
2c9130a244
@ -1,4 +1,4 @@
|
|||||||
const {Router, static} = require('express');
|
const {Router} = require('express');
|
||||||
const body = require('body-parser');
|
const body = require('body-parser');
|
||||||
|
|
||||||
const {getData, handleError} = require('./util');
|
const {getData, handleError} = require('./util');
|
||||||
@ -207,7 +207,6 @@ module.exports = function MembersApi({
|
|||||||
|
|
||||||
/* http */
|
/* http */
|
||||||
const staticRouter = Router();
|
const staticRouter = Router();
|
||||||
staticRouter.use('/static', static(require('path').join(__dirname, './static/auth/dist')));
|
|
||||||
staticRouter.get('/gateway', (req, res) => {
|
staticRouter.get('/gateway', (req, res) => {
|
||||||
res.status(200).send(`
|
res.status(200).send(`
|
||||||
<script>
|
<script>
|
||||||
@ -219,10 +218,6 @@ module.exports = function MembersApi({
|
|||||||
staticRouter.get('/bundle.js', (req, res) => {
|
staticRouter.get('/bundle.js', (req, res) => {
|
||||||
res.status(200).sendFile(require('path').join(__dirname, './static/gateway/bundle.js'));
|
res.status(200).sendFile(require('path').join(__dirname, './static/gateway/bundle.js'));
|
||||||
});
|
});
|
||||||
staticRouter.get('/*', (req, res) => {
|
|
||||||
res.status(200).sendFile(require('path').join(__dirname, './static/auth/dist/index.html'));
|
|
||||||
});
|
|
||||||
|
|
||||||
/* http */
|
/* http */
|
||||||
router.use('/api', apiRouter);
|
router.use('/api', apiRouter);
|
||||||
router.use('/static', staticRouter);
|
router.use('/static', staticRouter);
|
||||||
|
Loading…
Reference in New Issue
Block a user