diff --git a/Tools.ps1 b/Tools.ps1 index 9b167f1..b2dd152 100644 --- a/Tools.ps1 +++ b/Tools.ps1 @@ -789,5 +789,11 @@ Function ZeroPad-Decimal { Return $splitNumbers[0] + '.' + $paddedDecimal } +# Function to follow a URL and return the absolute URI of the result (whether redirected or not) +Function Get-AbsoluteURI { + param([string]$URL) + Return [System.Net.HttpWebRequest]::Create($URL).GetResponse().ResponseUri.AbsoluteUri +} + Setup-MSPDirectories Setup-LogFile \ No newline at end of file