fix backup await
This commit is contained in:
parent
6330ebd01d
commit
542a77fbef
3 changed files with 3 additions and 3 deletions
|
@ -54,7 +54,7 @@ export async function createManualBackup(req: Request, res: Response): Promise<a
|
||||||
export async function restoreBackupByLocalFile(req: Request, res: Response): Promise<any> {
|
export async function restoreBackupByLocalFile(req: Request, res: Response): Promise<any> {
|
||||||
let filename = req.body.filename;
|
let filename = req.body.filename;
|
||||||
let partial = req.body.partial;
|
let partial = req.body.partial;
|
||||||
let include = req.body.includes;
|
let include = req.body.include;
|
||||||
|
|
||||||
await BackupHelper.loadBackup({ filename, include, partial });
|
await BackupHelper.loadBackup({ filename, include, partial });
|
||||||
|
|
|
@ -120,7 +120,7 @@ export default abstract class BackupHelper {
|
||||||
throw new InternalException("partial and include have to be set correctly for restoring backup.");
|
throw new InternalException("partial and include have to be set correctly for restoring backup.");
|
||||||
}
|
}
|
||||||
|
|
||||||
dataSource.manager
|
await dataSource.manager
|
||||||
.transaction(async (transaction) => {
|
.transaction(async (transaction) => {
|
||||||
this.transactionManager = transaction;
|
this.transactionManager = transaction;
|
||||||
|
|
||||||
|
|
|
@ -7,7 +7,7 @@ import {
|
||||||
getGeneratedBackups,
|
getGeneratedBackups,
|
||||||
restoreBackupByLocalFile,
|
restoreBackupByLocalFile,
|
||||||
uploadBackupFile,
|
uploadBackupFile,
|
||||||
} from "../../../controller/admin/club/backupController";
|
} from "../../../controller/admin/user/backupController";
|
||||||
|
|
||||||
const storage = multer.diskStorage({
|
const storage = multer.diskStorage({
|
||||||
destination: (req, file, cb) => {
|
destination: (req, file, cb) => {
|
||||||
|
|
Loading…
Reference in a new issue