removed all Promise.resolve, Promise.reject and changed _.each to _.forEach to match ES5 (also in lo-dash, the main fn is forEach not each)