Huge News!Announcing our $40M Series B led by Abstract Ventures.Learn More
Socket
Sign inDemoInstall
Socket

asyncbox

Package Overview
Dependencies
Maintainers
1
Versions
36
Alerts
File Explorer

Advanced tools

Socket logo

Install Socket

Detect and block malicious and high-risk dependencies

Install

asyncbox - npm Package Compare versions

Comparing version 2.3.1 to 2.3.2

.eslintrc

42

build/lib/asyncbox.js

@@ -107,3 +107,3 @@ require('source-map-support').install();

var wrapped;
var count, wrapped;
return _regeneratorRuntime.async(function retryInterval$(context$1$0) {

@@ -114,2 +114,4 @@ var _this = this;

case 0:
count = 0;
wrapped = function wrapped() {

@@ -120,29 +122,36 @@ var res;

case 0:
count++;
res = undefined;
context$2$0.prev = 1;
context$2$0.next = 4;
context$2$0.prev = 2;
context$2$0.next = 5;
return _regeneratorRuntime.awrap(fn.apply(undefined, args));
case 4:
case 5:
res = context$2$0.sent;
context$2$0.next = 12;
context$2$0.next = 14;
break;
case 7:
context$2$0.prev = 7;
context$2$0.t0 = context$2$0['catch'](1);
context$2$0.next = 11;
case 8:
context$2$0.prev = 8;
context$2$0.t0 = context$2$0['catch'](2);
if (!(count !== times)) {
context$2$0.next = 13;
break;
}
context$2$0.next = 13;
return _regeneratorRuntime.awrap(sleep(sleepMs));
case 11:
case 13:
throw context$2$0.t0;
case 12:
case 14:
return context$2$0.abrupt('return', res);
case 13:
case 15:
case 'end':
return context$2$0.stop();
}
}, null, _this, [[1, 7]]);
}, null, _this, [[2, 8]]);
};

@@ -152,3 +161,3 @@

case 2:
case 3:
case 'end':

@@ -178,2 +187,3 @@ return context$1$0.stop();

function nodeify(promisey, cb) {
// eslint-disable-line promise/prefer-await-to-callbacks
return _bluebird2['default'].resolve(promisey).nodeify(cb);

@@ -509,2 +519,4 @@ }

exports.waitForCondition = waitForCondition;
//# sourceMappingURL=data:application/json;base64,eyJ2ZXJzaW9uIjozLCJzb3VyY2VzIjpbImxpYi9hc3luY2JveC5qcyJdLCJuYW1lcyI6W10sIm1hcHBpbmdzIjoiOzs7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iAgbGV0IGRlYnVnID0gb3B0cy5sb2dnZXIgPyBvcHRzLmxvZ2dlci5kZWJ1Zy5iaW5kKG9wdHMubG9nZ2VyKSA6IF8ubm9vcDtcbiAgbGV0IGJlZ3VuQXQgPSBEYXRlLm5vdygpO1xuICBsZXQgZW5kQXQgPSBiZWd1bkF0ICsgb3B0cy53YWl0TXM7XG4gIGxldCBzcGluID0gYXN5bmMgKCkgPT4ge1xuICAgIGlmIChhd2FpdCBjb25kRm4oKSkge1xuICAgICAgcmV0dXJuO1xuICAgIH1cbiAgICBsZXQgbm93ID0gRGF0ZS5ub3coKTtcbiAgICBsZXQgd2FpdGVkID0gbm93IC0gYmVndW5BdDtcbiAgICBpZiAobm93IDwgZW5kQXQpIHtcbiAgICAgIGRlYnVnKGBXYWl0ZWQgZm9yICR7d2FpdGVkfSBtcyBzbyBmYXJgKTtcbiAgICAgIGF3YWl0IEIuZGVsYXkob3B0cy5pbnRlcnZhbE1zKTtcbiAgICAgIGF3YWl0IHNwaW4oKTtcbiAgICB9IGVsc2Uge1xuICAgICAgdGhyb3cgbmV3IEVycm9yKGBDb25kaXRpb24gdW5tZXQgYWZ0ZXIgJHt3YWl0ZWR9IG1zLiBUaW1pbmcgb3V0LmApO1xuICAgIH1cbiAgfTtcbiAgYXdhaXQgc3BpbigpO1xufVxuXG5leHBvcnQgeyBzbGVlcCwgcmV0cnksIG5vZGVpZnksIG5vZGVpZnlBbGwsIHJldHJ5SW50ZXJ2YWwsIGFzeW5jaWZ5LCBwYXJhbGxlbCxcbiAgICAgICAgIGFzeW5jbWFwLCBhc3luY2ZpbHRlciwgd2FpdEZvckNvbmRpdGlvbn07XG4iXX0=
// do not pause when finished the last retry
//# sourceMappingURL=data:application/json;charset=utf8;base64,eyJ2ZXJzaW9uIjozLCJzb3VyY2VzIjpbImxpYi9hc3luY2JveC5qcyJdLCJuYW1lcyI6W10sIm1hcHBpbmdzIjoiOzs7Ozs7Ozs7Ozs7Ozs7Ozs7d0JBRWMsVUF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gcmV0cnlJbnRlcnZhbCwgYXN5bmNpZnksIHBhcmFsbGVsLFxuICAgICAgICAgYXN5bmNtYXAsIGFzeW5jZmlsdGVyLCB3YWl0Rm9yQ29uZGl0aW9ufTtcbiJdLCJzb3VyY2VSb290IjoiLi4vLi4ifQ==
"use strict";
var gulp = require('gulp'),
boilerplate = require('appium-gulp-plugins').boilerplate.use(gulp);
const gulp = require('gulp');
const boilerplate = require('appium-gulp-plugins').boilerplate.use(gulp);
boilerplate({build: "Asyncbox", jscs: false});
boilerplate({build: "Asyncbox"});

@@ -30,3 +30,5 @@ // transpile:main

async function retryInterval (times, sleepMs, fn, ...args) {
let count = 0;
let wrapped = async () => {
count++;
let res;

@@ -36,3 +38,6 @@ try {

} catch (e) {
await sleep(sleepMs);
// do not pause when finished the last retry
if (count !== times) {
await sleep(sleepMs);
}
throw e;

@@ -49,3 +54,3 @@ }

function nodeify (promisey, cb) {
function nodeify (promisey, cb) { // eslint-disable-line promise/prefer-await-to-callbacks
return B.resolve(promisey).nodeify(cb);

@@ -52,0 +57,0 @@ }

@@ -9,10 +9,5 @@ {

],
"version": "2.3.1",
"version": "2.3.2",
"author": "jlipps@gmail.com",
"licenses": [
{
"type": "apache-2.0",
"url": "https://raw.github.com/jlipps/asyncbox/master/LICENSE"
}
],
"license": "Apache-2.0",
"repository": {

@@ -34,19 +29,27 @@ "type": "git",

"dependencies": {
"babel-runtime": "=5.5.5",
"babel-runtime": "=5.8.24",
"bluebird": "^2.9.34",
"chai": "^3.2.0",
"chai-as-promised": "^5.1.0",
"es6-mapify": "^1.0.0",
"lodash": "^3.10.1",
"es6-mapify": "^1.1.0",
"lodash": "^4.17.4",
"source-map-support": "^0.3.1"
},
"scripts": {
"prepublish": "$(npm bin)/gulp prepublish",
"test": "$(npm bin)/gulp once",
"watch": "$(npm bin)/gulp"
"prepublish": "gulp prepublish",
"test": "gulp once",
"e2e-test": "gulp e2e-test",
"build": "gulp transpile",
"lint": "gulp eslint",
"watch": "gulp watch"
},
"devDependencies": {
"appium-gulp-plugins": "^1.0.3",
"appium-gulp-plugins": "^2.2.0",
"eslint": "^3.18.0",
"eslint-config-appium": "^2.0.1",
"eslint-plugin-babel": "^3.3.0",
"eslint-plugin-import": "^2.2.0",
"eslint-plugin-mocha": "^4.7.0",
"eslint-plugin-promise": "^3.3.1",
"gulp": "^3.8.11",
"mochawait": "^2.0.0",
"request": "^2.47.0",

@@ -53,0 +56,0 @@ "should": "^7.0.4"

SocketSocket SOC 2 Logo

Product

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

Packages

npm

Stay in touch

Get open source security insights delivered straight into your inbox.


  • Terms
  • Privacy
  • Security

Made with ⚡️ by Socket Inc