Sign Up

Sign Up to our social questions and Answers Engine to ask questions, answer people’s questions, and connect with other people.

Have an account? Sign In

Have an account? Sign In Now

Sign In

Login to our social questions & Answers Engine to ask questions answer people’s questions & connect with other people.

Sign Up Here

Forgot Password?

Don't have account, Sign Up Here

Forgot Password

Lost your password? Please enter your email address. You will receive a link and will create a new password via email.

Have an account? Sign In Now

You must login to ask a question.

Forgot Password?

Need An Account, Sign Up Here

Please briefly explain why you feel this question should be reported.

Please briefly explain why you feel this answer should be reported.

Please briefly explain why you feel this user should be reported.

Sign InSign Up

The Archive Base

The Archive Base Logo The Archive Base Logo

The Archive Base Navigation

  • Home
  • SEARCH
  • About Us
  • Blog
  • Contact Us
Search
Ask A Question

Mobile menu

Close
Ask a Question
  • Home
  • Add group
  • Groups page
  • Feed
  • User Profile
  • Communities
  • Questions
    • New Questions
    • Trending Questions
    • Must read Questions
    • Hot Questions
  • Polls
  • Tags
  • Badges
  • Buy Points
  • Users
  • Help
  • Buy Theme
  • SEARCH
Home/ Questions/Q 8017723
In Process

The Archive Base Latest Questions

Editorial Team
  • 0
Editorial Team
Asked: June 4, 20262026-06-04T20:55:34+00:00 2026-06-04T20:55:34+00:00

This piece of code was taken straight out of the example from: https://github.com/caolan/async#seriestasks-callback var

  • 0

This piece of code was taken straight out of the example from: https://github.com/caolan/async#seriestasks-callback

var async = require("async");
async.series([
    function() { console.log("a"); },
    function() { console.log("b"); }
], function(err, results){
    console.log(err);
    console.log(results);
});

However it doesn’t work. It stops after printing “a”.

Is it a bug with the latest build of async module or my usage have some issue?

  • 1 1 Answer
  • 0 Views
  • 0 Followers
  • 0
Share
  • Facebook
  • Report

Leave an answer
Cancel reply

You must login to add an answer.

Forgot Password?

Need An Account, Sign Up Here

1 Answer

  • Voted
  • Oldest
  • Recent
  • Random
  1. Editorial Team
    Editorial Team
    2026-06-04T20:55:35+00:00Added an answer on June 4, 2026 at 8:55 pm

    The functions you provide in the array passed into async.series need to accept a callback parameter that the function calls when the task is complete. So you’d want to do this instead:

    async.series([
        function(callback){ 
            console.log("a"); 
            callback();
        },
        function(callback){ 
            console.log("b");
            callback();
        }
    ]...
    
    • 0
    • Reply
    • Share
      Share
      • Share on Facebook
      • Share on Twitter
      • Share on LinkedIn
      • Share on WhatsApp
      • Report

Sidebar

Related Questions

In this piece of code taken from http://drdobbs.com/cpp/184403774 : template <class L, class R>
I am trying to run this piece of code taken from http://coffeescriptcookbook.com embedding it
This piece of code has been taken from a game built with XNA framework.
Taken from this SO thread , this piece of code calculates the number of
This piece of code is from Adobe docs : package { import flash.display.Loader; import
I have the following piece of code that is taken from a mock exam
I want to refactor this piece of code, it takes input from a form,
I'm trying to compile this piece of code from the book The C Programming
I have this small piece of code that basically takes a list and runs
This piece of code compiles and runs as expected on GCC 3.x and 4.x:

Explore

  • Home
  • Add group
  • Groups page
  • Communities
  • Questions
    • New Questions
    • Trending Questions
    • Must read Questions
    • Hot Questions
  • Polls
  • Tags
  • Badges
  • Users
  • Help
  • SEARCH

Footer

© 2021 The Archive Base. All Rights Reserved
With Love by The Archive Base

Insert/edit link

Enter the destination URL

Or link to existing content

    No search term specified. Showing recent items. Search or use up and down arrow keys to select an item.