ignore moar errors
This commit is contained in:
parent
6332d9baa0
commit
16fe736cd3
1 changed files with 3 additions and 2 deletions
5
index.js
5
index.js
|
@ -56,12 +56,13 @@ async function main () {
|
|||
}
|
||||
|
||||
process.on('uncaughtException', error => {
|
||||
if (error.stack.includes('protodef')) {
|
||||
if (error.stack.includes('protodef') || error.code === 'Z_BUF_ERROR') {
|
||||
console.error('Uncaught protodef exception!\n' + error.stack)
|
||||
return // Ignore protodef-related errors (packet-related)
|
||||
}
|
||||
|
||||
throw error
|
||||
console.error(error)
|
||||
process.exit(1)
|
||||
})
|
||||
}
|
||||
|
||||
|
|
Loading…
Reference in a new issue