Skip to content

Commit

Permalink
Browse files Browse the repository at this point in the history
Don't add t/ prefix to videos that don't need processing
  • Loading branch information
regalijan committed Mar 26, 2024
1 parent a7c7b42 commit 09fae05
Showing 1 changed file with 6 additions and 1 deletion.
7 changes: 6 additions & 1 deletion functions/api/reports/submit.ts
Expand Up @@ -163,7 +163,12 @@ export async function onRequestPost(context: RequestContext) {
)}${Date.now()}`;

uploadUrlPromises.push(
upload(context.env, `t/${fileUploadKey}`, file.size, fileExten),
upload(
context.env,
`${["mp4", "m4v", "webm"].includes(fileExten.toLowerCase()) ? "" : "t/"}${fileUploadKey}`,
file.size,
fileExten,
),
);

if (!["mp4", "m4v", "webm"].includes(fileExten)) {
Expand Down

0 comments on commit 09fae05

Please sign in to comment.