raimohanska/bacon.js — pull request #7 by lautis (2012-09-02 14:46:30+00:00)
Title: Handle bus.end() without subscribers

The following code throws `TypeError: undefined is not a function`

Bacon = (require 'src/Bacon').Bacon
bus = new Bacon.Bus()
bus.end()

To fix this, I've added check for existence of `sink` like other methods in Bus.