Skip to content

Commit a6b55ed

Browse files
Merge pull request KelvinTegelaar#1800 from KelvinTegelaar/dev
Dev
2 parents f9362fa + d8cbc43 commit a6b55ed

File tree

17 files changed

+15
-6
lines changed

17 files changed

+15
-6
lines changed

Modules/CIPPCore/Public/Add-CIPPApplicationPermission.ps1

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -11,6 +11,7 @@ function Add-CIPPApplicationPermission {
1111
}
1212
if ($RequiredResourceAccess -eq 'CIPPDefaults') {
1313

14+
Set-Location (Get-Item $PSScriptRoot).FullName
1415
$Permissions = Get-CippSamPermissions -NoDiff
1516
$RequiredResourceAccess = [System.Collections.Generic.List[object]]::new()
1617

Modules/CIPPCore/Public/Add-CIPPDelegatedPermission.ps1

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -8,6 +8,7 @@ function Add-CIPPDelegatedPermission {
88
$TenantFilter
99
)
1010
Write-Host 'Adding Delegated Permissions'
11+
Set-Location (Get-Item $PSScriptRoot).FullName
1112

1213
if ($ApplicationId -eq $env:ApplicationID -and $TenantFilter -eq $env:TenantID) {
1314
#return @('Cannot modify delgated permissions for CIPP-SAM on partner tenant')

Modules/CIPPCore/Public/Entrypoints/HTTP Functions/Tenant/Administration/Alerts/Invoke-PublicWebhooks.ps1

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -8,6 +8,7 @@ function Invoke-PublicWebhooks {
88
param($Request, $TriggerMetadata)
99
$Headers = $Request.Headers
1010

11+
Set-Location (Get-Item $PSScriptRoot).Parent.FullName
1112
$WebhookTable = Get-CIPPTable -TableName webhookTable
1213
$WebhookIncoming = Get-CIPPTable -TableName WebhookIncoming
1314
$Webhooks = Get-CIPPAzDataTableEntity @WebhookTable

Modules/CIPPCore/Public/Entrypoints/HTTP Functions/Tools/GitHub/Invoke-ListCommunityRepos.ps1

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -24,7 +24,7 @@ function Invoke-ListCommunityRepos {
2424

2525
if (!$Request.Query.WriteAccess) {
2626
$CIPPRoot = (Get-Item (Get-Module -Name CIPPCore).ModuleBase).Parent.Parent.FullName
27-
$CommunityRepos = Join-Path -Path $CIPPRoot -ChildPath 'Resources\CommunityRepos.json'
27+
$CommunityRepos = Join-Path -Path $CIPPRoot -ChildPath 'CommunityRepos.json'
2828
$DefaultCommunityRepos = Get-Content -Path $CommunityRepos -Raw | ConvertFrom-Json
2929

3030
$DefaultsMissing = $false

Modules/CIPPCore/Public/Get-CIPPTimerFunctions.ps1

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -40,7 +40,7 @@ function Get-CIPPTimerFunctions {
4040
}
4141

4242
$CIPPRoot = (Get-Item $CIPPCoreModuleRoot).Parent.Parent
43-
$CippTimers = Get-Content -Path $CIPPRoot\Resources\CIPPTimers.json
43+
$CippTimers = Get-Content -Path $CIPPRoot\CIPPTimers.json
4444

4545
if ($ListAllTasks) {
4646
$Orchestrators = $CippTimers | ConvertFrom-Json | Sort-Object -Property Priority

Modules/CIPPCore/Public/GraphHelper/New-passwordString.ps1

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -10,7 +10,7 @@ function New-passwordString {
1010
$SettingsTable = Get-CippTable -tablename 'Settings'
1111
$PasswordType = (Get-CIPPAzDataTableEntity @SettingsTable).passwordType
1212
if ($PasswordType -eq 'Correct-Battery-Horse') {
13-
$Words = Get-Content .\Resources\words.txt
13+
$Words = Get-Content .\words.txt
1414
(Get-Random -InputObject $words -Count 4) -join '-'
1515
} else {
1616
# Generate a complex password with a maximum of 100 tries

Modules/CIPPCore/Public/Test-CIPPAccessPermissions.ps1

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -25,6 +25,7 @@ function Test-CIPPAccessPermissions {
2525
}
2626
$Success = $true
2727
try {
28+
Set-Location (Get-Item $PSScriptRoot).FullName
2829
$null = Get-CIPPAuthentication
2930
$GraphToken = Get-GraphToken -returnRefresh $true -SkipCache $true
3031
if ($GraphToken) {

0 commit comments

Comments
 (0)