diff --git a/FFUDevelopment/BuildFFUVM.ps1 b/FFUDevelopment/BuildFFUVM.ps1 index a878ff7..e0a253d 100644 --- a/FFUDevelopment/BuildFFUVM.ps1 +++ b/FFUDevelopment/BuildFFUVM.ps1 @@ -2023,7 +2023,7 @@ function Get-WindowsESD { $OriginalVerbosePreference = $VerbosePreference $VerbosePreference = 'SilentlyContinue' Mark-DownloadInProgress -FFUDevelopmentPath $FFUDevelopmentPath -TargetPath $esdFilePath - Invoke-WebRequest -Uri $file.FilePath -OutFile $esdFilePath -Headers $Headers -UserAgent $UserAgent + Start-BitsTransferWithRetry -Source $file.FilePath -Destination $esdFilePath Clear-DownloadInProgress -FFUDevelopmentPath $FFUDevelopmentPath -TargetPath $esdFilePath $VerbosePreference = $OriginalVerbosePreference WriteLog "Download succeeded" @@ -2037,8 +2037,6 @@ function Get-WindowsESD { } } - - function Get-ODTURL { try { [String]$ODTPage = Invoke-WebRequest 'https://www.microsoft.com/en-us/download/details.aspx?id=49117' -Headers $Headers -UserAgent $UserAgent -ErrorAction Stop