MCPcopy
hub / github.com/mongodb/node-mongodb-native / isNodeShuttingDownError

Function isNodeShuttingDownError

src/error.ts:1522–1524  ·  view source on GitHub ↗
(err: MongoError)

Source from the content-addressed store, hash-verified

1520}
1521
1522export function isNodeShuttingDownError(err: MongoError): boolean {
1523 return !!(typeof err.code === 'number' && SDAM_NODE_SHUTTING_DOWN_ERROR_CODES.has(err.code));
1524}
1525
1526/**
1527 * Determines whether SDAM can recover from a given error. If it cannot

Callers 1

handleErrorMethod · 0.90

Calls 1

hasMethod · 0.45

Tested by

no test coverage detected