continuing to improve the promise method error handling