Skip to content

Commit 7f78c70

Browse files
committed
Update Invoke-ExecCommunityRepo.ps1
1 parent 52f857d commit 7f78c70

1 file changed

Lines changed: 2 additions & 1 deletion

File tree

Modules/CIPPHTTP/Public/Entrypoints/HTTP Functions/Tools/GitHub/Invoke-ExecCommunityRepo.ps1

Lines changed: 2 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -160,6 +160,7 @@ function Invoke-ExecCommunityRepo {
160160
$Path = $Request.Body.Path
161161
$FullName = $Request.Body.FullName
162162
$Branch = $Request.Body.Branch
163+
$Force = [bool]$Request.Body.Force
163164
try {
164165
$Template = Get-GitHubFileContents -FullName $FullName -Path $Path -Branch $Branch
165166

@@ -178,7 +179,7 @@ function Invoke-ExecCommunityRepo {
178179
(Get-GitHubFileContents -FullName $FullName -Branch $Branch -Path $Location.path).content | ConvertFrom-Json
179180
}
180181
}
181-
$ImportResult = Import-CommunityTemplate -Template $Content -SHA $Template.sha -MigrationTable $MigrationTable -LocationData $LocationData -Source $FullName
182+
$ImportResult = Import-CommunityTemplate -Template $Content -SHA $Template.sha -MigrationTable $MigrationTable -LocationData $LocationData -Source $FullName -Force:$Force
182183

183184
$Results = @{
184185
resultText = $ImportResult ?? 'Template imported'

0 commit comments

Comments
 (0)