Kinvey/node-background-task — pull request #16 by mjsalinger (2014-02-20 11:37:19+00:00)
Title: Timeout race fix

A race condition that was fixed in 0.6.7 still had conditions in which it could occur, as the clean maps and kill executed in the callback of stopTask. This change cleans the maps before any async calls are made, and checks to see if the callbacks still exist before proceeding.