How does new promise terminate chained calls?

adds a promise with a chained call, and
calls three ajax,
. I want to terminate the promise without the next two calls when the first one returns an error. How to do


throw new Error ();
once an error is thrown, all then chains will be skipped and jumped directly to catch

MySQL Query : SELECT * FROM `codeshelper`.`v9_news` WHERE status=99 AND catid='6' ORDER BY rand() LIMIT 5
MySQL Error : Disk full (/tmp/#sql-temptable-64f5-1b360c1-2bfd7.MAI); waiting for someone to free some space... (errno: 28 "No space left on device")
MySQL Errno : 1021
Message : Disk full (/tmp/#sql-temptable-64f5-1b360c1-2bfd7.MAI); waiting for someone to free some space... (errno: 28 "No space left on device")
Need Help?