diff options
author | B Paul Anderson <benpaul.anderson@gmail.com> | 2016-05-02 21:10:58 -0500 |
---|---|---|
committer | B Paul Anderson <benpaul.anderson@gmail.com> | 2016-05-02 21:10:58 -0500 |
commit | 81e888fd40e99c0de0098a7554d6cdafc540c021 (patch) | |
tree | 07156112708bd258b2c0c1d76b3e7104a28f8d7f /lib | |
parent | 63bee74d1091b488c622ea88cbffa514cf9aaef0 (diff) | |
download | async-81e888fd40e99c0de0098a7554d6cdafc540c021.tar.gz |
Re-introduce nonexistent dependency check
Diffstat (limited to 'lib')
-rw-r--r-- | lib/auto.js | 5 |
1 files changed, 5 insertions, 0 deletions
diff --git a/lib/auto.js b/lib/auto.js index 925db77..c36bb8f 100644 --- a/lib/auto.js +++ b/lib/auto.js @@ -134,6 +134,11 @@ export default function (tasks, concurrency, callback) { uncheckedDependencies[key] = remainingDependencies; arrayEach(dependencies, function (dependencyName) { + if (!tasks[dependencyName]) { + throw new Error('async.auto task `' + key + + '` has a non-existent dependency in ' + + dependencies.join(', ')); + } addListener(dependencyName, function () { remainingDependencies--; if (remainingDependencies === 0) { |