Return a list of threads from HandlerList#dispatch #121

Merged
merged 1 commit into from Jun 13, 2013

Conversation

Projects
None yet
2 participants
Contributor

nickrw commented Jun 12, 2013

I have a plugin which wants to block on the execution of an event (being used as a hook to trigger other plugins to act). This pull request changes the return values of:

Handler#call: now returns the Thread it added to @thread_group
HandlerList#dispatch: now returns an array of Threads the event started

These methods previously returned void.

This allows this proof-of-concept plugin to run as expected: https://gist.github.com/nickrw/5769705

Have HandlerList#dispatch return an array of threads started by the e…
…vent.

This allows plugins to wait for handler threads to complete, if desired.

@dominikh dominikh merged commit 62931f9 into cinchrb:master Jun 13, 2013

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment