Secure your code as it's written. Use Snyk Code to scan source code in minutes - no build needed - and fix issues immediately.
app.get('/logfiles/', function(req, res, next) {
listLogFiles(app, (err, files) => {
if (err) {
console.error(err)
res.status(500)
res.send('Error reading logfiles list')
return
}
res.json(files)
})
})
app.get('/logfiles/:filename', function(req, res, next) {