Remove dead code
Avoid chdir and pass the absolute file path to the output option for wget and curl
DownloadTask improvement, chdir removed.