rewrite downloader