amiga-whdload-game-scripts icon indicating copy to clipboard operation
amiga-whdload-game-scripts copied to clipboard

Change to download_whdownload_games.ps1 needed - webclient.download throws exception

Open egnichtel opened this issue 5 years ago • 1 comments

Line 93 of download_whdownload_games.ps1:

$webclient.DownloadFile($whdownloadGameUrl, $whdloadGameFile)

Throws and exception due to webclient not accepting path as part of the second parameter (it appears this was tightened up in the latest versions of .net).

To get around this, I changed line 93 to:

Invoke-Webrequest -Uri $whdownloadGameUrl -OutFile $whdloadGameFile

And that seems to work correctly.

This may be an issue in other scripts in your repo. (Thanks for writing these - they are very useful).

egnichtel avatar May 01 '19 21:05 egnichtel

Thanks for the tip. I will update the scripts to use the powershell command Invoke-Webrequest

henrikstengaard avatar May 27 '19 12:05 henrikstengaard