1
0
Fork 0
mirror of synced 2024-06-29 11:31:06 +12:00

Merge remote-tracking branch 'origin/feature/app-backups' into feature/backups-ui

This commit is contained in:
Peter Clement 2022-10-19 18:32:57 +01:00
commit 93e3bda6ac

View file

@ -6,6 +6,7 @@ import {
uploadDirectory,
upload,
} from "../../../utilities/fileSystem/utilities"
import { downloadTemplate } from "../../../utilities/fileSystem"
import { ObjectStoreBuckets, FieldTypes } from "../../../constants"
import { join } from "path"
import fs from "fs"
@ -89,7 +90,7 @@ async function getTemplateStream(template: TemplateType) {
return fs.createReadStream(template.file.path)
} else if (template.key) {
const [type, name] = template.key.split("/")
const tmpPath = await exports.downloadTemplate(type, name)
const tmpPath = await downloadTemplate(type, name)
return fs.createReadStream(join(tmpPath, name, "db", "dump.txt"))
}
}