News for hackers. Stuff that matters.
Re:JavaScript Promises: There and back again by spion on Tuesday December 17, 2013 @07:20PM (#6924964)
Those are not entirely equivalent. For example, if you make a typo when writing "user" or "u", the first one will catch that typo (cannot get property name of undefined) while the second one will not.

  Users.get(1234)
    .then(u => u.name)
    .catch(ex => 1/* do whatever */);

There are no comments on this comment yet.