Revert "External promise library"

This reverts commit 7e918c9565a258d883e92ee9d7868690b821684b.