turn any node-style callback function into a promise-returning one.