Skip to content

Commit

Permalink
Browse files Browse the repository at this point in the history
Actually fix attachment url issue
  • Loading branch information
regalijan committed Oct 19, 2023
1 parent edb6aff commit 5d76957
Showing 1 changed file with 3 additions and 1 deletion.
4 changes: 3 additions & 1 deletion functions/api/reports/submit.ts
Expand Up @@ -188,7 +188,9 @@ export async function onRequestPost(context: RequestContext) {
for (const urlResult of uploadUrlResults as PromiseFulfilledResult<string>[]) {
uploadUrls.push(urlResult.value);

let url = new URL(urlResult.value).searchParams.get("name") as string;
let url = (
new URL(urlResult.value).searchParams.get("name") as string
).replace(/^t\//, "");

attachments.push(url);
}
Expand Down

0 comments on commit 5d76957

Please sign in to comment.