changed to escape quotation marks in filenames

This commit is contained in:
uh wot 2022-01-04 03:23:00 +01:00
parent b868166b89
commit 30a7c29192
Signed by: uhwot
GPG Key ID: CB2454984587B781
2 changed files with 2 additions and 2 deletions

2
dist/worker.js vendored

File diff suppressed because one or more lines are too long

View File

@ -309,7 +309,7 @@ async function track(id, format, tagging) {
const headers = { const headers = {
'content-type': formats[format].mime, 'content-type': formats[format].mime,
'content-disposition': `inline; filename="${title.replaceAll('"', '_')} [${id}].${formats[format].ext}"` 'content-disposition': `inline; filename="${title.replaceAll('"', '\\"')} [${id}].${formats[format].ext}"`
} }
return new Response(readable, { status: 200, headers }) return new Response(readable, { status: 200, headers })