documentcloud/backbone — pull request #673 by lawrencepit (2011-10-16 23:07:32+00:00)
Title: "Collection: add into sorted position" + index is passed in 'add' event

When a Collection has a +comparator+ defined, then when adding an object the +add+ event handler needs to know at which position the object was inserted into. This patch passes the +index+ to the +add+ event handler.