chore: fix format
This commit is contained in:
parent
550f472451
commit
5268838975
1 changed files with 2 additions and 2 deletions
|
|
@ -25,11 +25,11 @@ export const upload = new Elysia().use(userService).post(
|
|||
if (body?.file) {
|
||||
if (Array.isArray(body.file)) {
|
||||
for (const file of body.file) {
|
||||
const santizedFileName = sanitize(file.name)
|
||||
const santizedFileName = sanitize(file.name);
|
||||
await Bun.write(`${userUploadsDir}${santizedFileName}`, file);
|
||||
}
|
||||
} else {
|
||||
const santizedFileName = sanitize(body.file["name"])
|
||||
const santizedFileName = sanitize(body.file["name"]);
|
||||
await Bun.write(`${userUploadsDir}${santizedFileName}`, body.file);
|
||||
}
|
||||
}
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue