正在显示
2 个修改的文件
包含
4 行增加
和
1 行删除
@@ -36,7 +36,7 @@ exports = module.exports = function (settings, proxy, logger) { | @@ -36,7 +36,7 @@ exports = module.exports = function (settings, proxy, logger) { | ||
36 | if (checkAuth(req)) | 36 | if (checkAuth(req)) |
37 | proxy.web(req, res, next); | 37 | proxy.web(req, res, next); |
38 | else | 38 | else |
39 | - res.redirect(settings.proxy.signInUrl); | 39 | + res.redirect("/login"); |
40 | }); | 40 | }); |
41 | } | 41 | } |
42 | }; | 42 | }; |
@@ -7,6 +7,9 @@ exports = module.exports = function (settings, logger) { | @@ -7,6 +7,9 @@ exports = module.exports = function (settings, logger) { | ||
7 | router.get('/', function (req, res, next) { | 7 | router.get('/', function (req, res, next) { |
8 | res.render('index', { 'csrfToken': 'xxxx' }); | 8 | res.render('index', { 'csrfToken': 'xxxx' }); |
9 | }); | 9 | }); |
10 | + router.get('/login', function (req, res, next) { | ||
11 | + res.render('index', { 'csrfToken': 'xxxx' }); | ||
12 | + }); | ||
10 | app.use('/', router); | 13 | app.use('/', router); |
11 | app.use(settings.proxy.signOutUrl, function (req, res, next) { | 14 | app.use(settings.proxy.signOutUrl, function (req, res, next) { |
12 | req.session.token = null; | 15 | req.session.token = null; |
请
注册
或
登录
后发表评论