From eecb9e7b72d020d5d146887c5e478c9ee83f1b94 Mon Sep 17 00:00:00 2001 From: Regalijan Date: Tue, 26 Mar 2024 03:06:09 -0400 Subject: [PATCH] Fix r2 metadata fetching --- functions/api/reports/complete.ts | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/functions/api/reports/complete.ts b/functions/api/reports/complete.ts index 8b1643e..4efccfb 100644 --- a/functions/api/reports/complete.ts +++ b/functions/api/reports/complete.ts @@ -41,7 +41,7 @@ export async function onRequestPost(context: RequestContext) { for (const attachment of coconutData.attachments) { const token = crypto.randomUUID(); - const objectMeta = await context.env.R2.head(attachment); + const objectMeta = await context.env.R2.head(`t/${attachment}`); if (!objectMeta) continue;