a denodify (aka promisify) function built on lie