Permalink
Browse files

add missing var

  • Loading branch information...
2 parents 7b64084 + 993dd63 commit 605d6bf7274dfd26f9d5eb81d40869b3e99c2ee3 @tmpvar tmpvar committed Mar 19, 2011
Showing with 3 additions and 1 deletion.
  1. +3 −1 lib/jsdom/level2/events.js
View
4 lib/jsdom/level2/events.js
@@ -178,7 +178,9 @@ events.EventTarget.getListeners = function getListeners(target, type, capturing)
};
events.EventTarget.dispatch = function dispatch(event, iterator, capturing) {
- var target = iterator();
+ var listeners,
+ target = iterator();
+
while (target && !event._stopPropagation) {
listeners = events.EventTarget.getListeners(target, event._type, capturing);
for (var y = 0; y < listeners.length; y++) {

0 comments on commit 605d6bf

Please sign in to comment.