lib/mixlib/install/generator/powershell/scripts/helpers.ps1 in mixlib-install-1.0.12 vs lib/mixlib/install/generator/powershell/scripts/helpers.ps1 in mixlib-install-1.0.13
- old
+ new
@@ -19,10 +19,16 @@
}
function New-Uri {
param ($baseuri, $newuri)
+ try {
new-object System.Uri $baseuri, $newuri
+ }
+ catch [System.Management.Automation.MethodInvocationException]{
+ Write-Error "$($_.exception.message)"
+ throw $_.exception
+ }
}
function Get-WebContent {
param ($uri, $filepath)
$proxy = New-Object -TypeName System.Net.WebProxy