mirror of
https://codeberg.org/yeentown/barkey.git
synced 2025-12-11 09:28:24 +00:00
use logger instead of console for uncaughtException debug lines
This commit is contained in:
parent
283facdd31
commit
bf455c2f7a
1 changed files with 2 additions and 2 deletions
|
|
@ -66,13 +66,13 @@ async function main() {
|
|||
process.on('uncaughtException', (err) => {
|
||||
// Workaround for https://github.com/node-fetch/node-fetch/issues/954
|
||||
if (String(err).match(/^TypeError: .+ is an? url with embedded credentials.$/)) {
|
||||
console.debug('Suppressed node-fetch issue#954, but the current job may fail.');
|
||||
logger.debug('Suppressed node-fetch issue#954, but the current job may fail.');
|
||||
return;
|
||||
}
|
||||
|
||||
// Workaround for https://github.com/node-fetch/node-fetch/issues/1845
|
||||
if (String(err) === 'TypeError: Cannot read properties of undefined (reading \'body\')') {
|
||||
console.debug('Suppressed node-fetch issue#1845, but the current job may fail.');
|
||||
logger.debug('Suppressed node-fetch issue#1845, but the current job may fail.');
|
||||
return;
|
||||
}
|
||||
|
||||
|
|
|
|||
Loading…
Add table
Reference in a new issue