tmp
reimplement io.download as a Promise