mirror of
https://github.com/ether/etherpad-lite.git
synced 2025-04-21 07:56:16 -04:00
15 lines
No EOL
427 B
JavaScript
15 lines
No EOL
427 B
JavaScript
var path = require("path");
|
|
|
|
exports.expressCreateServer = function (hook_name, args, cb) {
|
|
args.app.get('/tests/frontend/*', function (req, res) {
|
|
var subPath = req.url.substr("/tests/frontend".length);
|
|
if (subPath == ""){
|
|
subPath = "index.html"
|
|
}
|
|
|
|
var filePath = path.normalize(__dirname + "/../../../../tests/frontend/")
|
|
filePath += subPath.replace("..", "");
|
|
|
|
res.sendfile(filePath);
|
|
});
|
|
} |