check for null arguments when calling Install-Program
This commit is contained in:
@@ -179,7 +179,10 @@ Function Install-Program {
|
|||||||
)
|
)
|
||||||
If ( Test-Path "${Path}" ) {
|
If ( Test-Path "${Path}" ) {
|
||||||
LogMsg "Running installer: ""${Path}"" ${Arguments}"
|
LogMsg "Running installer: ""${Path}"" ${Arguments}"
|
||||||
Try { Start-Process "${Path}" -ArgumentList "${Arguments}" -Wait }
|
Try {
|
||||||
|
If ( $Arguments -eq '' ) { Start-Process "${Path}" -Wait }
|
||||||
|
Else { Start-Process "${Path}" -ArgumentList "${Arguments}" -Wait }
|
||||||
|
}
|
||||||
Catch { LogErr $_.Exception.Message }
|
Catch { LogErr $_.Exception.Message }
|
||||||
LogMsg "Installer finished"
|
LogMsg "Installer finished"
|
||||||
If ( $Delete ) {
|
If ( $Delete ) {
|
||||||
|
|||||||
Reference in New Issue
Block a user