Support iterating over objects in Promise.map