Skip to content

Commit 85937d8

Browse files
committed
backup tweaks, fix DA issue
1 parent 57a38c7 commit 85937d8

3 files changed

Lines changed: 4 additions & 4 deletions

File tree

Modules/CIPPCore/Public/Entrypoints/Activity Triggers/Domain Analyser/Push-DomainAnalyserDomain.ps1

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -6,7 +6,7 @@ function Push-DomainAnalyserDomain {
66
param($Item)
77
$DomainTable = Get-CippTable -tablename 'Domains'
88
$Filter = "PartitionKey eq 'TenantDomains' and RowKey eq '{0}'" -f $Item.RowKey
9-
$DomainObject = Get-CIPPAzDataTableEntity @DomainTable -Filter $Filter
9+
$DomainObject = Get-CIPPAzDataTableEntity @DomainTable -Filter $Filter | Select-Object * -ExcludeProperty table
1010

1111
try {
1212
$ConfigTable = Get-CippTable -tablename Config
@@ -35,7 +35,7 @@ function Push-DomainAnalyserDomain {
3535
try {
3636
$Tenant = $DomainObject.TenantDetails | ConvertFrom-Json -ErrorAction Stop
3737
} catch {
38-
$Tenant = @{Tenant = 'None' }
38+
$Tenant = @{ Tenant = 'None' }
3939
}
4040

4141
$Result = [PSCustomObject]@{

Modules/CIPPCore/Public/Entrypoints/HTTP Functions/CIPP/Settings/Invoke-ExecRestoreBackup.ps1

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -17,7 +17,7 @@ Function Invoke-ExecRestoreBackup {
1717
Write-Host ($line)
1818
$Table = Get-CippTable -tablename $line.table
1919
$ht2 = @{}
20-
$line.psobject.properties | ForEach-Object { $ht2[$_.Name] = [string]$_.Value }
20+
$line.psobject.properties | Where-Object { $_.Name -ne 'table' } | ForEach-Object { $ht2[$_.Name] = [string]$_.Value }
2121
$Table.Entity = $ht2
2222
Add-CIPPAzDataTableEntity @Table -Force
2323

Modules/CIPPCore/Public/New-CIPPBackup.ps1

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -24,7 +24,7 @@ function New-CIPPBackup {
2424
)
2525
$CSVfile = foreach ($CSVTable in $BackupTables) {
2626
$Table = Get-CippTable -tablename $CSVTable
27-
Get-AzDataTableEntity @Table | Select-Object *, @{l = 'table'; e = { $CSVTable } } -ExcludeProperty DomainAnalyser
27+
Get-AzDataTableEntity @Table | Select-Object * -ExcludeProperty DomainAnalyser, table | Select-Object *, @{l = 'table'; e = { $CSVTable } }
2828
}
2929
$RowKey = 'CIPPBackup' + '_' + (Get-Date).ToString('yyyy-MM-dd-HHmm')
3030
$CSVfile

0 commit comments

Comments
 (0)