Skip to content

Commit 40accfb

Browse files
authored
Merge pull request #3603 from Dokploy/3581-duplicating-a-database-fails-with-unique-constraint-violation-backup_appname_unique
fix(project): include appName in backup processing
2 parents 7ae3d7d + 3f0558d commit 40accfb

1 file changed

Lines changed: 4 additions & 4 deletions

File tree

apps/dokploy/server/api/routers/project.ts

Lines changed: 4 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -506,7 +506,7 @@ export const projectRouter = createTRPCRouter({
506506
}
507507

508508
for (const backup of backups) {
509-
const { backupId, ...rest } = backup;
509+
const { backupId, appName: _appName, ...rest } = backup;
510510
await createBackup({
511511
...rest,
512512
postgresId: newPostgres.postgresId,
@@ -542,7 +542,7 @@ export const projectRouter = createTRPCRouter({
542542
}
543543

544544
for (const backup of backups) {
545-
const { backupId, ...rest } = backup;
545+
const { backupId, appName: _appName, ...rest } = backup;
546546
await createBackup({
547547
...rest,
548548
mariadbId: newMariadb.mariadbId,
@@ -578,7 +578,7 @@ export const projectRouter = createTRPCRouter({
578578
}
579579

580580
for (const backup of backups) {
581-
const { backupId, ...rest } = backup;
581+
const { backupId, appName: _appName, ...rest } = backup;
582582
await createBackup({
583583
...rest,
584584
mongoId: newMongo.mongoId,
@@ -614,7 +614,7 @@ export const projectRouter = createTRPCRouter({
614614
}
615615

616616
for (const backup of backups) {
617-
const { backupId, ...rest } = backup;
617+
const { backupId, appName: _appName, ...rest } = backup;
618618
await createBackup({
619619
...rest,
620620
mysqlId: newMysql.mysqlId,

0 commit comments

Comments
 (0)