Make changes for video processing check
This commit is contained in:
@ -189,15 +189,6 @@ export async function onRequestPost(context: RequestContext) {
|
||||
uploadUrls.push(urlResult.value);
|
||||
|
||||
let url = new URL(urlResult.value).searchParams.get("name") as string;
|
||||
const extension = (url.split(".").at(-1) as string).toLowerCase();
|
||||
|
||||
if (["mkv", "wmv"].includes(extension)) {
|
||||
url = url.replace(`.${extension}`, ".mp4");
|
||||
|
||||
await context.env.DATA.put(`videoprocessing_${url}`, "1", {
|
||||
expirationTtl: 600,
|
||||
});
|
||||
}
|
||||
|
||||
attachments.push(url);
|
||||
}
|
||||
|
Reference in New Issue
Block a user