spoike/refluxjs — pull request #84 by krawaller (2014-09-25 18:32:55+00:00)
Title: refactor Reflux.all

This PR refactors the code for `Reflux.all`.

I found the prior implementation, returning a hacked action, to be a bit dangerous. What we get back is both a listener and a publisher, which means it is really a store! By implementing as such instead we get shorter code, and we can get rid of the extra `hasListener` method which was needed earlier since the action was moonlighting as a listener.

As a bonus, by using `ListenerMethods.listenTo` instead of directly calling `PublisherMethods.listen`, we get an object which can clean up itself.

Less LOC:s, less debt and headache waiting to happen.

There is an ever so slight API breakage as we no longer get back a functor, but I doubt it was ever used in such a way.