Fix versioning for npm. *sadpanda*
Fix sort() bug when ids.length is 0. Fixes #74
Added test for bug #74.