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

after-all

Package Overview
Dependencies
Maintainers
1
Versions
11
Alerts
File Explorer

Advanced tools

Socket logo

Install Socket

Detect and block malicious and high-risk dependencies

Install

after-all - npm Package Compare versions

Comparing version 0.0.1 to 0.0.2

5

index.js

@@ -8,5 +8,6 @@ module.exports = function(afterAllCb) {

return function thecallback(err) {
return function thecallback() {
var args = arguments;
process.nextTick(function() {
cb.apply(null, arguments);
cb.apply(null, args);
if (--calls === 0) afterAllCb();

@@ -13,0 +14,0 @@ });

2

package.json
{
"name": "after-all",
"version": "0.0.1",
"version": "0.0.2",
"description": "Execute several async functions and get a callback when they are all done",

@@ -5,0 +5,0 @@ "main": "index.js",

@@ -56,2 +56,11 @@ var afterAll = require('../index');

});
it('should pass the arguments to the original callbacks', function(done) {
var next = afterAll(function() {
done();
});
(next(function(a) { a.should.eql(2)}))(2);
(next(function(b) { b.should.eql('hi')}))('hi');
});
});
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