Skip to content

Commit

Permalink
Fixed bug recently introduced preventing plugin events to trigger
Browse files Browse the repository at this point in the history
  • Loading branch information
tj committed Apr 30, 2010
1 parent 451679c commit 37d490c
Show file tree
Hide file tree
Showing 2 changed files with 6 additions and 2 deletions.
2 changes: 1 addition & 1 deletion Makefile
@@ -1,4 +1,4 @@

AB = ab
ABFLAGS = -n 3000 -c 50
NODE = node
Expand Down
6 changes: 5 additions & 1 deletion lib/express/request.js
Expand Up @@ -321,7 +321,11 @@ exports.Request = new Class({
if (err || complete === total)
callback(err)
else {
if (plugins[complete++].trigger(new Event(name, data), next) !== true)
// TODO: remove when this issue is resolved...
if (plugins[complete] === undefined)
++complete,
next()
else if (plugins[complete++].trigger(new Event(name, data), next) !== true)
next()
}
})()
Expand Down

0 comments on commit 37d490c

Please sign in to comment.