optimize download without progressbar

This commit is contained in:
Baipyrus 2024-11-25 15:03:16 +01:00
parent 107b83ced4
commit fa7d942a8f

View File

@ -78,9 +78,16 @@ function ProcessUrlFiles
param (
[string]$source,
[Parameter(Mandatory=$false)][string]$destination,
[Parameter(Mandatory=$false)][string]$fileExt
[Parameter(Mandatory=$false)][string]$fileExt,
[bool]$progress=$true
)
# Disable progressbar for faster download
$progressPreference = 'continue'
if (-not $progress)
{ $progressPreference = 'silentlyContinue'
}
# Ensure the destination directory exists
if ($destination -and (-not (Test-Path $destination)))
{