Fixed issue with both complete and error firing at the same time