summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorAlex Early <alexander.early@gmail.com>2016-02-26 18:00:51 -0800
committerAlex Early <alexander.early@gmail.com>2016-02-26 18:00:51 -0800
commit7ee15953293b5ca8e173ab281742c3dfdcc5df50 (patch)
tree7e6c2f93a947404fd9180e506af02a69d716a04c
parentd1ef64c306399edd83dc0fd57ad25eb3c7d645fa (diff)
parent0bb98fc5b34d8dadade6265dbe48b41127e56ee5 (diff)
downloadasync-7ee15953293b5ca8e173ab281742c3dfdcc5df50.tar.gz
Merge pull request #1039 from lgaticaq/master
Fix async.filter example
-rw-r--r--README.md8
1 files changed, 4 insertions, 4 deletions
diff --git a/README.md b/README.md
index 06ec85b..e73c12f 100644
--- a/README.md
+++ b/README.md
@@ -36,9 +36,9 @@ async.map(['file1','file2','file3'], fs.stat, function(err, results){
async.filter(['file1','file2','file3'], function(filePath, callback) {
fs.access(filePath, function(err) {
- callback(null, !err)
+ callback(!err)
});
-}, function(err, results){
+}, function(results){
// results now equals an array of the existing files
});
@@ -417,9 +417,9 @@ __Example__
```js
async.filter(['file1','file2','file3'], function(filePath, callback) {
fs.access(filePath, function(err) {
- callback(null, !err)
+ callback(!err)
});
-}, function(err, results){
+}, function(results){
// results now equals an array of the existing files
});
```