Almost completed the promises refactor.