summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorMithgol <getgit@mithgol.ru>2014-03-30 22:55:50 -0700
committerMithgol <getgit@mithgol.ru>2014-03-30 22:55:50 -0700
commitd7efd38a0cb82f7220703b6f2c38b5dde9a8361e (patch)
tree5dd7c1bb4fd50cf7da7001bd79c08626b696cba3
parentcdec81fb3bfdedf847f79e9feeab92d1d7ea31d8 (diff)
downloadasync-d7efd38a0cb82f7220703b6f2c38b5dde9a8361e.tar.gz
improve `.auto` docs
-rw-r--r--README.md9
1 files changed, 5 insertions, 4 deletions
diff --git a/README.md b/README.md
index de34420..1a85777 100644
--- a/README.md
+++ b/README.md
@@ -1242,10 +1242,11 @@ async.auto({
__Arguments__
-* `tasks` - An object literal (containing named functions) or an array (of
- requirements, with the function itself the last item in the array). The key
- used for each function or array is used when specifying requirements. The
- function receives two arguments: (1) a `callback(err, result)` which must be
+* `tasks` - An object. Each of its properties is either a function or an array of
+ requirements, with the function itself the last item in the array. The object's key
+ of a property serves as the name of the task defined by that property,
+ i.e. can be used when specifying requirements for other tasks.
+ The function receives two arguments: (1) a `callback(err, result)` which must be
called when finished, passing an `error` (which can be `null`) and the result of
the function's execution, and (2) a `results` object, containing the results of
the previously executed functions.