The way to define if promise2 created by promise1 throw then method