A RetroSearch Logo

Home - News ( United States | United Kingdom | Italy | Germany ) - Football scores

Search Query:

Showing content from https://github.com/vweevers/transient-error below:

vweevers/transient-error: Mark an error as transient, meaning you can retry.

transient-error

Mark an error as transient, meaning you can retry.

Usage
const transient = require('transient-error')
const err = transient(new Error('Could not connect'))

A consumer can then do:

if (err.transient) {
  // Retry
}

Becomes useful when multiple modules use this, as a simple contract.

Install

With npm do:

npm install transient-error
License

MIT © 2020-present Vincent Weevers


RetroSearch is an open source project built by @garambo | Open a GitHub Issue

Search and Browse the WWW like it's 1997 | Search results from DuckDuckGo

HTML: 3.2 | Encoding: UTF-8 | Version: 0.7.4