add force parameter to win_get_url

This commit is contained in:
Tal Auslander 2015-06-09 11:14:44 +03:00 committed by Matt Clay
parent 26a54897a2
commit 9c6d829991

View file

@ -40,7 +40,9 @@ Else {
Fail-Json $result "missing required argument: dest" Fail-Json $result "missing required argument: dest"
} }
If (-not (Test-Path $dest)) { $force = Get-Attr -obj $params -name "force" "no"
If ($force -eq "yes" -or -not (Test-Path $dest)) {
$client = New-Object System.Net.WebClient $client = New-Object System.Net.WebClient
Try { Try {