-
-
Notifications
You must be signed in to change notification settings - Fork 10.6k
Allow infinite ActiveState change listeners. #222
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Conversation
Fixes a warning from event-emitter when using more than ten Links (or other components using the ActiveState mixin).
I think this seems reasonable to me… |
Fix for an error being thrown in Routes.js - updateMatchComponents.
@@ -281,7 +281,7 @@ function getRootMatch(matches) { | |||
|
|||
function updateMatchComponents(matches, refs) { | |||
var i = 0, component; | |||
while (component = refs[REF_NAME]) { | |||
while ((component = refs[REF_NAME]) && (matches[i+1] !== undefined)) { |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
What's this all about? I remember debugging this code a while ago, can't remember why I was here though.
I'd like to know whats happening, not just prevent an error from happening.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Oh shit, that's not supposed to be there, I commited it to my fork after submitting the pull request. Didn't realize it would be added here (like I said, I'm new at this). Anyway, it's my proposed fix for #117.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
One thing at a time :)
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Reverted :)
This reverts commit fa4127f.
closed by edbfd25 |
Fixes a warning from event-emitter when using more than ten Links (or
other components using the ActiveState mixin) by allowing an unlimited number of listeners (as suggested here: http://nodejs.org/docs/latest/api/events.html#events_emitter_setmaxlisteners_n).
This is to try to fix issue #220.
Or would it be better to somehow group event listeners? Or is there some other way of solving this problem?
(Sorry if I'm doing this wrong, haven't done a pull request before.)