log unhandled errors by default

This commit is contained in:
Robert Dyer
2024-07-01 15:11:32 -05:00
parent bc1cd4e7e8
commit 573f3ea5d2
+5
View File
@@ -3,6 +3,11 @@ require("dotenv").config();
module.exports = {
openBudget: async function () {
process.on('unhandledRejection', (reason, p) => {
console.log('Unhandled Rejection at: Promise', p, 'reason:', reason);
console.log(reason.stack);
});
const url = process.env.ACTUAL_SERVER_URL || '';
const password = process.env.ACTUAL_SERVER_PASSWORD || '';
const file_password = process.env.ACTUAL_FILE_PASSWORD || '';