>From my point of view, rejection is the way to communicate "out-of-domain" values. So, in your scenario, the domain of answers has two values "accept" and "reject" or "deny" (to avoid confusion) so you should handle these two answers in the resolved handler.
Hope it helps. El 01/02/2015 17:53, "Domenic Denicola" <[email protected]> escribió: > From: es-discuss [mailto:[email protected]] On Behalf Of > Gray Zhang > > > Therefore, I’d like to ask whether we should ONLY use Promise as a > return-or-throw synonyms, or we should use it in a yes-or-no scenario > > You should only use the rejection channel of promises for exceptional > situations, similar to what you would use synchronous exceptions for. > > > http://www.w3.org/2001/tag/doc/promises-guide#rejections-should-be-exceptional > > _______________________________________________ > es-discuss mailing list > [email protected] > https://mail.mozilla.org/listinfo/es-discuss >
_______________________________________________ es-discuss mailing list [email protected] https://mail.mozilla.org/listinfo/es-discuss

