Permalink
Browse files

v3.3.8. Improvement.

- v3.3.8 February 5, 2014
	- More descriptive error when a task is fired without a method to fire
  • Loading branch information...
1 parent 13a8057 commit b0d239291c9d3b196c5cf97e2bed0b65f360c0ce @balupton balupton committed Feb 4, 2014
Showing with 10 additions and 4 deletions.
  1. +3 −0 HISTORY.md
  2. +3 −3 package.json
  3. +4 −1 src/lib/taskgroup.coffee
View
@@ -1,5 +1,8 @@
# History
+- v3.3.8 February 5, 2014
+ - More descriptive error when a task is fired without a method to fire
+
- v3.3.7 January 30, 2014
- Improvements around adding tasks to task groups and passing arguments to Task and TaskGroup constructors
View
@@ -1,7 +1,7 @@
{
"title": "TaskGroup",
"name": "taskgroup",
- "version": "3.3.7",
+ "version": "3.3.8",
"description": "Group together synchronous and asynchronous tasks and execute them with support for concurrency, naming, and nesting.",
"homepage": "https://github.com/bevry/taskgroup",
"license": {
@@ -51,9 +51,9 @@
},
"devDependencies": {
"coffee-script": "~1.7.1",
- "joe": "~1.3.0",
+ "joe": "~1.3.2",
"joe-reporter-console": "~1.2.1",
- "chai": "~1.8.1",
+ "chai": "~1.9.0",
"projectz": "~0.3.9"
},
"directories": {
View
@@ -154,7 +154,10 @@ class Task extends EventEmitter
# Listen for uncaught errors
fire = ->
try
- ambi(me.config.method.bind(me), args...)
+ if me.config.method?.bind
+ ambi(me.config.method.bind(me), args...)
+ else
+ throw new Error("The task #{me.config.name} was fired but has no method to fire")
catch err
me.uncaughtExceptionCallback(err)

0 comments on commit b0d2392

Please sign in to comment.