return when sending json

This commit is contained in:
teddit 2021-03-20 17:30:58 +01:00
parent e938822277
commit 15250a1c00
1 changed files with 1 additions and 1 deletions

View File

@ -1650,7 +1650,7 @@ module.exports = (app, redis, fetch, RedditAPI) => {
if(export_to_file === 'on') {
res.setHeader('Content-disposition', 'attachment; filename=teddit_prefs.json')
res.setHeader('Content-type', 'application/json')
res.send(req.cookies)
return res.send(req.cookies)
}
let r = `${(Math.random().toString(36)+'00000000000000000').slice(2, 10+2).toUpperCase()}`