Set the content type header for XML files.

This commit is contained in:
Daniel Ceregatti 2023-09-12 15:13:18 -07:00
parent 87e5baf345
commit 6da2c62eea

View file

@ -217,6 +217,7 @@ app.get('/mod/:modId/:file', (req, res) => {
const file = req.params["file"]
if (fs.existsSync(config.modDir + d + modId + d + file)) {
const contents = fs.readFileSync(config.modDir + d + modId + d + file)
res.set('Content-type', 'application/xml')
res.send(contents)
}
})