Skip to content
This repository has been archived by the owner on Jun 28, 2024. It is now read-only.

Commit

Permalink
Define OutputType
Browse files Browse the repository at this point in the history
  • Loading branch information
SamErde committed Jun 21, 2024
1 parent bb2f1c5 commit 1a89603
Showing 1 changed file with 7 additions and 0 deletions.
7 changes: 7 additions & 0 deletions Get-OUDetails.ps1
Original file line number Diff line number Diff line change
Expand Up @@ -10,6 +10,11 @@ function Get-OUDetails {
I would rather display an explicit value (eg: $false) than a null that implies $false. Likewise, I prefer to
display a $true or $false rather than 1 or a 0.
#>
[CmdletBinding()]
[OutputType([Array])]
param (
)

Import-Module ActiveDirectory

$OUs = Get-ADOrganizationalUnit -Filter * -Properties CanonicalName, gPOptions, isCriticalSystemObject, showInAdvancedViewOnly | Sort-Object CanonicalName
Expand Down Expand Up @@ -54,6 +59,7 @@ function Get-ParentOU {
function Get-ChildOU {
# List the child OUs for an organizational unit in Active Directory
[CmdletBinding()]
[OutputType([Array])]
param (
[Parameter()]
$OrganizationalUnit
Expand All @@ -68,6 +74,7 @@ function Get-ChildOU {
function Test-BlockInheritence {
# Check if Block Inheritence is set on an organizational unit in Active Directory
[CmdletBinding()]
[OutputType([Boolean])]
param (
[Parameter()]
$OrganizationalUnit
Expand Down

0 comments on commit 1a89603

Please sign in to comment.