2022-03-22 13:39:01 +00:00
|
|
|
function Get-WAUUpdateStatus{
|
2022-03-26 15:02:00 +00:00
|
|
|
|
2022-03-22 13:39:01 +00:00
|
|
|
[xml]$UpdateStatus = Get-Content "$WorkingDir\config\config.xml" -Encoding UTF8 -ErrorAction SilentlyContinue
|
2022-03-26 15:02:00 +00:00
|
|
|
|
|
|
|
#Check if AutoUpdate is enabled
|
2022-03-22 13:39:01 +00:00
|
|
|
if ($true -eq $UpdateStatus.app.WAUautoupdate){
|
|
|
|
Write-Log "WAU AutoUpdate is Enabled" "Green"
|
2022-03-26 15:02:00 +00:00
|
|
|
$Script:WAUautoupdate = $true
|
|
|
|
|
|
|
|
#Check if pre-release versions are enabled
|
|
|
|
if ($true -eq $UpdateStatus.app.WAUprerelease){
|
|
|
|
Write-Log "WAU AutoUpdate Pre-release enabled" "Cyan"
|
|
|
|
$Script:WAUprerelease = $true
|
|
|
|
}
|
|
|
|
else{
|
|
|
|
$Script:WAUprerelease = $false
|
|
|
|
}
|
2022-03-22 13:39:01 +00:00
|
|
|
}
|
|
|
|
else{
|
|
|
|
Write-Log "WAU AutoUpdate is Disabled" "Grey"
|
2022-03-26 15:02:00 +00:00
|
|
|
$Script:WAUautoupdate = $false
|
2022-03-22 13:39:01 +00:00
|
|
|
}
|
|
|
|
}
|