fix: backup file dir of sub apps (#4985)

This commit is contained in:
ChengLei Shao 2024-08-07 18:07:58 +08:00 committed by GitHub
parent c25be38e45
commit 5f09674b9c
No known key found for this signature in database
GPG Key ID: B5690EEEBB952194

View File

@ -165,7 +165,13 @@ export class Dumper extends AppMigrator {
}
backUpStorageDir() {
return path.resolve(process.cwd(), 'storage', 'backups');
const paths = [process.cwd(), 'storage', 'backups'];
if (this.app.name !== 'main') {
paths.push(this.app.name);
}
return path.resolve(...paths);
}
async allBackUpFilePaths(options?: { includeInProgress?: boolean; dir?: string }) {