Browse Source

feat(nocodb): add ENOTFOUND & ECONNREFUSED

pull/5154/head
Wing-Kam Wong 2 years ago
parent
commit
5ad3d50485
  1. 10
      packages/nocodb/src/lib/version-upgrader/ncUpgradeErrors.ts

10
packages/nocodb/src/lib/version-upgrader/ncUpgradeErrors.ts

@ -1,5 +1,13 @@
export function throwTimeoutError(e, timeoutErrorInfo) {
if (['EHOSTDOWN', 'ETIMEDOUT', 'EHOSTUNREACH'].includes(e.code)) {
if (
[
'EHOSTDOWN',
'ETIMEDOUT',
'EHOSTUNREACH',
'ENOTFOUND',
'ECONNREFUSED',
].includes(e.code)
) {
let db = '';
if (timeoutErrorInfo.connection.filename) {
// for sqlite

Loading…
Cancel
Save