News for hackers. Stuff that matters.
Re:Async and Await by eyko on Thursday June 02, 2016 @05:37PM (#11826277)
You're still nesting. Considering the whole point the author made was that something went wrong with `filterUsersWithFriends`, then you would simply handle that in the next `.then`... So something like:

  export default function getUsers () {
    return getUsers()
      .then(users => filterUsersWithFriends)
      .then(getUsersLikes, trySomethingElse);
  }
would have been more than enough.
Re:Async and Await by md224 on Thursday June 02, 2016 @06:44PM (#11826736)
I think the problem with your solution is that trySomethingElse won't have access to the users variable unless the filterUsersWithFriends rejection explicitly passes it through.