Skip to content

Commit

Permalink
Remove auto-import. Didn't work. Move to function scope
Browse files Browse the repository at this point in the history
  • Loading branch information
Troy Harshberger committed Dec 4, 2024
1 parent fbf4ea4 commit 391157c
Show file tree
Hide file tree
Showing 2 changed files with 3 additions and 1 deletion.
2 changes: 2 additions & 0 deletions Modules/CIPPCore/Public/Set-PSAAssetDetail.ps1
Original file line number Diff line number Diff line change
Expand Up @@ -9,6 +9,8 @@ function Set-PSAAssetDetail {
$APIName = 'Set PSA Asset Detail'
)

Import-Module PS-NCentral

$MappingTable = Get-CIPPTable -TableName CippMapping
$Table = Get-CIPPTable -TableName Extensionsconfig
$Configuration = (Get-CIPPAzDataTableEntity @Table).config | ConvertFrom-Json -Depth 10
Expand Down
2 changes: 1 addition & 1 deletion profile.ps1
Original file line number Diff line number Diff line change
Expand Up @@ -13,7 +13,7 @@
# Remove this if you are not planning on using MSI or Azure PowerShell.

# Import modules
@('PS-NCentral','CIPPCore', 'CippExtensions', 'Az.KeyVault', 'Az.Accounts') | ForEach-Object {
@('CIPPCore', 'CippExtensions', 'Az.KeyVault', 'Az.Accounts') | ForEach-Object {
try {
$Module = $_
Import-Module -Name $_ -ErrorAction Stop
Expand Down

0 comments on commit 391157c

Please sign in to comment.