fixed error reporting problems

This commit is contained in:
Jan Prochazka
2023-02-25 20:25:27 +01:00
parent c817bf5911
commit 0c62349802
4 changed files with 20 additions and 25 deletions

View File

@@ -11,7 +11,7 @@ async function runScript(func) {
await func();
process.exit(0);
} catch (err) {
logger.error('Error running script', err);
logger.error({ err }, `Error running script: ${err.message}`);
process.exit(1);
}
}