Remove references to ValidateDCIMChoice for #40

This commit is contained in:
Ben Claussen 2023-03-10 14:37:35 -05:00
parent 6965f61e6e
commit 27209d6917
9 changed files with 0 additions and 50 deletions

View file

@ -73,10 +73,6 @@ function Get-NetboxDCIMDevice {
#endregion Parameters
process {
if ($null -ne $Status) {
$PSBoundParameters.Status = ValidateDCIMChoice -ProvidedValue $Status -DeviceStatus
}
$Segments = [System.Collections.ArrayList]::new(@('dcim', 'devices'))
$URIComponents = BuildURIComponents -URISegments $Segments.Clone() -ParametersDictionary $PSBoundParameters -SkipParameterByName 'Raw'

View file

@ -52,22 +52,6 @@ function New-NetboxDCIMDevice {
)
#endregion Parameters
# if ($null -ne $Device_Role) {
# # Validate device role?
# }
# if ($null -ne $Device_Type) {
# # Validate device type?
# }
# if ($null -ne $Status) {
# $PSBoundParameters.Status = ValidateDCIMChoice -ProvidedValue $Status -DeviceStatus
# }
# if ($null -ne $Face) {
# $PSBoundParameters.Face = ValidateDCIMChoice -ProvidedValue $Face -DeviceFace
# }
$Segments = [System.Collections.ArrayList]::new(@('dcim', 'devices'))
$URIComponents = BuildURIComponents -URISegments $Segments.Clone() -ParametersDictionary $PSBoundParameters

View file

@ -51,13 +51,7 @@ function Set-NetboxDCIMDevice {
)
begin {
# if ($null -ne $Status) {
# $PSBoundParameters.Status = ValidateDCIMChoice -ProvidedValue $Status -DeviceStatus
# }
# if ($null -ne $Face) {
# $PSBoundParameters.Face = ValidateDCIMChoice -ProvidedValue $Face -DeviceFace
# }
}
process {

View file

@ -34,10 +34,6 @@ function Add-NetboxDCIMInterface {
[uint16[]]$Tagged_VLANs
)
# if ($null -ne $Form_Factor) {
# $PSBoundParameters.Form_Factor = ValidateDCIMChoice -ProvidedValue $Form_Factor -InterfaceFormFactor
# }
if (-not [System.String]::IsNullOrWhiteSpace($Mode)) {
$PSBoundParameters.Mode = switch ($Mode) {
'Access' {

View file

@ -36,10 +36,6 @@ function Add-NetboxDCIMInterfaceConnection {
[uint16]$Interface_B
)
if ($null -ne $Connection_Status) {
$PSBoundParameters.Connection_Status = ValidateDCIMChoice -ProvidedValue $Connection_Status -InterfaceConnectionStatus
}
# Verify if both Interfaces exist
Get-NetboxDCIMInterface -Id $Interface_A -ErrorAction Stop | Out-null
Get-NetboxDCIMInterface -Id $Interface_B -ErrorAction Stop | Out-null

View file

@ -35,10 +35,6 @@ function Get-NetboxDCIMInterface {
)
process {
if ($null -ne $Form_Factor) {
$PSBoundParameters.Form_Factor = ValidateDCIMChoice -ProvidedValue $Form_Factor -InterfaceFormFactor
}
$Segments = [System.Collections.ArrayList]::new(@('dcim', 'interfaces'))
$URIComponents = BuildURIComponents -URISegments $Segments.Clone() -ParametersDictionary $PSBoundParameters

View file

@ -19,10 +19,6 @@ function Get-NetboxDCIMInterfaceConnection {
[switch]$Raw
)
if ($null -ne $Connection_Status) {
$PSBoundParameters.Connection_Status = ValidateDCIMChoice -ProvidedValue $Connection_Status -InterfaceConnectionStatus
}
$Segments = [System.Collections.ArrayList]::new(@('dcim', 'interface-connections'))
$URIComponents = BuildURIComponents -URISegments $Segments.Clone() -ParametersDictionary $PSBoundParameters -SkipParameterByName 'Raw'

View file

@ -38,10 +38,6 @@ function Set-NetboxDCIMInterface {
)
begin {
# if ($null -ne $Form_Factor) {
# $PSBoundParameters.Form_Factor = ValidateDCIMChoice -ProvidedValue $Form_Factor -InterfaceFormFactor
# }
if (-not [System.String]::IsNullOrWhiteSpace($Mode)) {
$PSBoundParameters.Mode = switch ($Mode) {
'Access' {

View file

@ -47,10 +47,6 @@ function Set-NetboxDCIMInterfaceConnection {
)
begin {
# if ($null -ne $Connection_Status) {
# $PSBoundParameters.Connection_Status = ValidateDCIMChoice -ProvidedValue $Connection_Status -InterfaceConnectionStatus
# }
if ((@($ID).Count -gt 1) -and ($Interface_A -or $Interface_B)) {
throw "Cannot set multiple connections to the same interface"
}