mirror of
https://github.com/sudoxnym/habitica.git
synced 2026-08-05 12:02:13 +00:00
fix(loggly): send more infos about cron errors
This commit is contained in:
parent
739d8885a3
commit
8b3c6f94bf
1 changed files with 7 additions and 1 deletions
|
|
@ -284,7 +284,13 @@ api.cron = function(req, res, next) {
|
|||
User.findById(user._id, cb);
|
||||
}
|
||||
], function(err, saved) {
|
||||
if(err) logging.loggly({error: "Cron caught", stack: err.stack || err});
|
||||
if(err) logging.loggly({
|
||||
error: "Cron caught",
|
||||
stack: (err.stack || err.message || err),
|
||||
body: req.body, headers: req.header,
|
||||
auth: (req.headers['x-api-user'] + ' | ' + req.headers['x-api-key']),
|
||||
originalUrl: req.originalUrl
|
||||
});
|
||||
res.locals.user = saved;
|
||||
next(err,saved);
|
||||
user = progress = quest = null;
|
||||
|
|
|
|||
Loading…
Reference in a new issue