jjzjj

javascript - 使用 errorCallback 突破 Promise "then"链

--编辑--我最近遇到了一件关于promises的奇怪事情,但我想这可能是因为它违反了promises的哲学。考虑以下代码://AssumingAuthisjustasimplelibdoinghttprequestswithpromisesAuth.signup().then(succCall,errCall).then(loginSucc,loginErr)//MycallbacksherefunctionsuccCall(){//OK,sendsecondpromiseconsole.log('succCall');returnAuth.login();}functionerrC