preventing callback to be executed twice when ready is rejected