Advertisement
Not a member of Pastebin yet?
Sign Up,
it unlocks many cool features!
- // thay vì
- e_nhau_khong()
- .then(uong_ruou)
- .then(hut_thuoc)
- .then(ve_nha)
- .catch(console.log);
- // nên viết thế này
- e_nhau_khong()
- .then(function(){
- return Promise.all([
- uong_ruou(),
- hut_thuoc()
- ])
- })
- .then(ve_nha)
- .catch(console.error.bind(console));
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement