visionmedia/consolidate.js — pull request #83 by ForbesLindesay (2013-01-06 00:49:37+00:00)
Title: Better handling of syncronous exceptions

This forces all errors thrown by consolidate.js to be asynchronous and passed to the callback properly. This simplifies the API usage since it means that:

1. Errors are always guaranteed to be observable (unlike when `fromStringRenderer` is used in the current implementation).
2. You only have to handle errors in one place because you know they will always be passed to the callback.

We also ensure that we only call the callback once. By wrapping error handling up in a helper method, the code is also a little bit cleaner.