Fixes to packagesz class code and the win package
This commit is contained in:
parent
8b2a4ca0cb
commit
4cec655429
|
@ -5,7 +5,7 @@
|
|||
{
|
||||
"custom": null,
|
||||
"System": [
|
||||
"Windows"
|
||||
"Desktop"
|
||||
],
|
||||
"Hostname": null,
|
||||
"Username": null,
|
||||
|
|
|
@ -44,7 +44,8 @@
|
|||
|
||||
$possibleValues
|
||||
})]
|
||||
[string[]]$ScriptName
|
||||
[string[]]$ScriptName,
|
||||
[switch]$WaitNotRequired = $env:WAIT_NOT_REQUIRED
|
||||
)
|
||||
|
||||
$local:EditRootPath=$MyPSScriptRoot
|
||||
|
|
|
@ -23,7 +23,7 @@ class Packagesz { #: System.Management.Automation.IValidateSetValuesGenerator {
|
|||
$local:valid = $Package.Condition[0].Logic -notin ([szLogic]::or, [szLogic]::ornot)
|
||||
$local:currentSys = [SystemName]::_GetValidValues('',$true,$true);
|
||||
$local:hostname = $(hostname)
|
||||
$local:username = $env:USER ?? $env:USERNAME
|
||||
$local:username = $( if( $env:USER ) { $env:USER } else { $env:USERNAME })
|
||||
foreach( $local:c in $Package.Condition ) {
|
||||
if( $valid -eq ($c.Logic -in ([szLogic]::or, [szLogic]::ornot )) ) { continue }
|
||||
|
||||
|
|
Loading…
Reference in New Issue