fixed some issues with getters
This commit is contained in:
parent
9a5552a1e1
commit
66281abe54
@ -4,7 +4,7 @@ param (
|
||||
$Server
|
||||
)
|
||||
|
||||
$Projects
|
||||
$Projects=$null
|
||||
if($PSBoundParameters.ContainsKey("Server")){
|
||||
$Projects = . .\GetProjects.ps1 -Server $Server
|
||||
} else {
|
||||
|
@ -8,7 +8,7 @@ param (
|
||||
)
|
||||
|
||||
if($PSBoundParameters.ContainsKey('Name')){
|
||||
$Roles
|
||||
$Roles=$null
|
||||
if($PSBoundParameters.ContainsKey('Server')){
|
||||
$Roles = . .\GetRoles.ps1 -Server $Server | Where-Object Name -Match $Name
|
||||
} else {
|
||||
|
@ -6,7 +6,7 @@ param (
|
||||
|
||||
. .\Variables.ps1
|
||||
if($PSBoundParameters.ContainsKey("Server")){
|
||||
Get-ADGroup -Server $Server -SearchBase $Projects
|
||||
Get-ADGroup -Server $Server -SearchBase $Projects -Filter 'GroupCategory -eq "Security"'
|
||||
} else {
|
||||
Get-ADGroup -SearchBase $Projects
|
||||
Get-ADGroup -SearchBase $Projects -Filter 'GroupCategory -eq "Security"'
|
||||
}
|
@ -4,7 +4,7 @@ param (
|
||||
$Server
|
||||
)
|
||||
|
||||
$Projects
|
||||
$Projects=$null
|
||||
if($PSBoundParameters.ContainsKey("Server")){
|
||||
$Projects = . .\GetProjects.ps1 -Server $Server
|
||||
} else {
|
||||
|
Loading…
Reference in New Issue
Block a user