From 1ec38d3da24135047b97fc36c044cbe2601e2b77 Mon Sep 17 00:00:00 2001 From: Ben Claussen Date: Thu, 16 Feb 2023 09:45:51 -0500 Subject: [PATCH] Add call to Get-NetboxContentType in Connect-NetboxAPI and NetboxConfigVariable storage --- Functions/Setup/Connect-NetboxAPI.ps1 | 4 +++- Functions/Setup/Support/SetupNetboxConfigVariable.ps1 | 1 + 2 files changed, 4 insertions(+), 1 deletion(-) diff --git a/Functions/Setup/Connect-NetboxAPI.ps1 b/Functions/Setup/Connect-NetboxAPI.ps1 index 5626dfb..974cfc6 100644 --- a/Functions/Setup/Connect-NetboxAPI.ps1 +++ b/Functions/Setup/Connect-NetboxAPI.ps1 @@ -144,7 +144,9 @@ } else { Write-Verbose "Found compatible version [$($script:NetboxConfig.NetboxVersion.'netbox-version')]!" } - + + $script:NetboxConfig.ContentTypes = Get-NetboxContentType -Limit 500 + $script:NetboxConfig.Connected = $true Write-Verbose "Successfully connected!" diff --git a/Functions/Setup/Support/SetupNetboxConfigVariable.ps1 b/Functions/Setup/Support/SetupNetboxConfigVariable.ps1 index a8ac41f..12e5e9c 100644 --- a/Functions/Setup/Support/SetupNetboxConfigVariable.ps1 +++ b/Functions/Setup/Support/SetupNetboxConfigVariable.ps1 @@ -13,6 +13,7 @@ 'Choices' = @{ } 'APIDefinition' = $null + 'ContentTypes' = $null } }