redirect /admin properly (fix #3114)

pull/3115/head
noerw 2017-01-06 18:18:55 +01:00
parent deed74c8c8
commit cc69e76200
1 changed files with 1 additions and 1 deletions

View File

@ -2,7 +2,7 @@ var eejs = require('ep_etherpad-lite/node/eejs');
exports.expressCreateServer = function (hook_name, args, cb) {
args.app.get('/admin', function(req, res) {
if('/' != req.path[req.path.length-1]) return res.redirect('/admin/');
if('/' != req.path[req.path.length-1]) return res.redirect('./admin/');
res.send( eejs.require("ep_etherpad-lite/templates/admin/index.html", {}) );
});
}