fix(project): include appName in backup processing

- Updated backup processing logic to destructure appName from backup objects, ensuring it is available for further operations.
- This change is applied consistently across multiple sections of the project router.
This commit is contained in:
Mauricio Siu
2026-02-05 15:03:22 -06:00
parent 7ae3d7d906
commit 3f0558d077

View File

@@ -506,7 +506,7 @@ export const projectRouter = createTRPCRouter({
}
for (const backup of backups) {
const { backupId, ...rest } = backup;
const { backupId, appName: _appName, ...rest } = backup;
await createBackup({
...rest,
postgresId: newPostgres.postgresId,
@@ -542,7 +542,7 @@ export const projectRouter = createTRPCRouter({
}
for (const backup of backups) {
const { backupId, ...rest } = backup;
const { backupId, appName: _appName, ...rest } = backup;
await createBackup({
...rest,
mariadbId: newMariadb.mariadbId,
@@ -578,7 +578,7 @@ export const projectRouter = createTRPCRouter({
}
for (const backup of backups) {
const { backupId, ...rest } = backup;
const { backupId, appName: _appName, ...rest } = backup;
await createBackup({
...rest,
mongoId: newMongo.mongoId,
@@ -614,7 +614,7 @@ export const projectRouter = createTRPCRouter({
}
for (const backup of backups) {
const { backupId, ...rest } = backup;
const { backupId, appName: _appName, ...rest } = backup;
await createBackup({
...rest,
mysqlId: newMysql.mysqlId,