Closed Abourass closed 3 years ago
I'm getting this error as well when attempting to backup or restore a db. It seems like res.send
is triggering the touch method as described here which throws an error if req.session
hasn't been modified.
app.get('/admin/restore', function(req, res)
{
var dir = path.join(__dirname, 'database');
exec('mongorestore --drop '+dir, function(e, stdout, stderr) {
log('* restoring database:', app.get('db_name'));
if (e) {
log(stderr);
res.status(500).send(e);
} else{
console.log('database successfully restored');
// modifying req.session w/ a random value avoids throwing an error but this shouldn't be required //
req.session.randomVal = Math.round(Math.random()*9999);
res.sendStatus(200);
}
});
});
Link: #390
Wait, did you guys update to the latest version? It fixed the issue. @braitsch @Abourass
I'm submitting a ... [x] bug report
Summary Quite often, after logging in, I'm getting this error while browsing through my app:
Other information
databaseConnect
And then I initialize in my app.ts