Socket
Socket
Sign inDemoInstall

betolerant

Package Overview
Dependencies
2
Maintainers
1
Versions
4
Alerts
File Explorer

Advanced tools

Install Socket

Detect and block malicious and high-risk dependencies

Install

betolerant

be tolerant


Version published
Maintainers
1
0

Weekly downloads

Readme

Source

betolerant

NPM Version Build Status

let betolerant = require("betolerant");

betolerant(3 /*tries*/, 10000 /*timeout*/, function* {
    yield asyncOp();
    yield sleep(1000);
    result = yield checkAsyncOpResult();
    if (!result.failed) {
        throw Error("op failed");
    }
}).then(function(){
    // done;
}).catch(function(){
    // all three attemps timed out or failed
});

Keywords

FAQs

Last updated on 10 Aug 2017

Did you know?

Socket for GitHub automatically highlights issues in each pull request and monitors the health of all your open source dependencies. Discover the contents of your packages and block harmful activity before you install or update your dependencies.

Install

Related posts

SocketSocket SOC 2 Logo

Product

  • Package Alerts
  • Integrations
  • Docs
  • Pricing
  • FAQ
  • Roadmap

Stay in touch

Get open source security insights delivered straight into your inbox.


  • Terms
  • Privacy
  • Security

Made with ⚡️ by Socket Inc