If winget can't be found - exit with error + text
parent
512584fbad
commit
78724ae344
|
@ -89,7 +89,7 @@ if (Test-Network) {
|
|||
}
|
||||
else {
|
||||
Write-Log "Critical: List doesn't exist, exiting..." "Red"
|
||||
New-Item "$WorkingDir\logs\list_error.txt" -Force
|
||||
New-Item "$WorkingDir\logs\list_error.txt" -Value "List doesn't exist!" -Force
|
||||
Exit 1
|
||||
}
|
||||
}
|
||||
|
@ -216,6 +216,11 @@ if (Test-Network) {
|
|||
Write-Log "User context execution not installed"
|
||||
}
|
||||
}
|
||||
else {
|
||||
Write-Log "Critical: An error occured, exiting..." "red"
|
||||
New-Item "$WorkingDir\logs\winget_error.txt" -Value "Winget not installed or detected!" -Force
|
||||
Exit 1
|
||||
}
|
||||
}
|
||||
|
||||
#End
|
||||
|
|
Loading…
Reference in New Issue