Forgot to un-comment the delete code
This commit is contained in:
1 parent
9f2fc3ec06
commit
2d429c6271
1 file changed
+2
-2
@@ -556,7 +556,7 @@ Function Copy-ContentLibrary {
|
|||||||
if($DeleteSourceFile) {
|
if($DeleteSourceFile) {
|
||||||
try {
|
try {
|
||||||
Write-Host -ForegroundColor Magenta "Deleteing" $sourceItemFile.Name "..."
|
Write-Host -ForegroundColor Magenta "Deleteing" $sourceItemFile.Name "..."
|
||||||
#$deleteResult = $contentLibaryItemService.delete($sourceItemFile.Id)
|
$deleteResult = $contentLibaryItemService.delete($sourceItemFile.Id)
|
||||||
} catch {
|
} catch {
|
||||||
Write-Host -ForegroundColor Red "Failed to delete" $sourceItemFile.Name
|
Write-Host -ForegroundColor Red "Failed to delete" $sourceItemFile.Name
|
||||||
$Error[0]
|
$Error[0]
|
||||||
@@ -570,7 +570,7 @@ Function Copy-ContentLibrary {
|
|||||||
if($DeleteSourceFile) {
|
if($DeleteSourceFile) {
|
||||||
try {
|
try {
|
||||||
Write-Host -ForegroundColor Magenta "Deleteing" $sourceItemFile.Name "..."
|
Write-Host -ForegroundColor Magenta "Deleteing" $sourceItemFile.Name "..."
|
||||||
#$deleteResult = $contentLibaryItemService.delete($sourceItemFile.Id)
|
$deleteResult = $contentLibaryItemService.delete($sourceItemFile.Id)
|
||||||
} catch {
|
} catch {
|
||||||
Write-Host -ForegroundColor Red "Failed to delete" $sourceItemFile.Name
|
Write-Host -ForegroundColor Red "Failed to delete" $sourceItemFile.Name
|
||||||
break
|
break
|
||||||
|
|||||||
Reference in new issue
Block a user