Vinícius Ernani de Carvalho 6c4544a079 Create the backend 5 tahun lalu
..
index.js 6c4544a079 Create the backend 5 tahun lalu
license 6c4544a079 Create the backend 5 tahun lalu
package.json 6c4544a079 Create the backend 5 tahun lalu
readme.md 6c4544a079 Create the backend 5 tahun lalu

readme.md

is-retry-allowed Build Status

Is retry allowed for Error?

Install

$ npm install --save is-retry-allowed

Usage

const isRetryAllowed = require('is-retry-allowed');

isRetryAllowed({code: 'ETIMEDOUT'});
//=> true

isRetryAllowed({code: 'ENOTFOUND'});
//=> false

isRetryAllowed({});
//=> true

API

isRetryAllowed(error)

error

Type: object

Object with code property, which will be used to determine retry.

License

MIT © Vsevolod Strukchinsky