feat: Add s3-compatible plugin for the file module (#7143)
This commit is contained in:
1 parent
abf1283ab6
commit
f341265f42
18 files changed
+1599
-4
No files matched your search
@@ -33,6 +33,8 @@ export default class FileModuleService implements FileTypes.IFileModuleService {
|
||||
data: CreateFileDTO[] | CreateFileDTO
|
||||
): Promise<FileDTO[] | FileDTO> {
|
||||
const input = Array.isArray(data) ? data : [data]
|
||||
// TODO: Validate file mime type, have config for allowed types
|
||||
|
||||
const files = await Promise.all(
|
||||
input.map((file) => this.fileProviderService_.upload(file))
|
||||
)
|
||||
|
||||
Reference in new issue
Block a user