Removed setImmediate usage to work in the browsers.