Ensure callbacks are not called synchronously

https://github.com/mapbox/mapbox.js/issues/472