Browse Source
Fix 500 error when downloading files with non-ASCII filenames
pull/2182/head
hongry
10 months ago
No known key found for this signature in database
GPG Key ID: 5C90DAFF6EC72C04
1 changed files with
1 additions and
1 deletions
-
src/server/routes/cnf/[oneTimeLink].ts
|
|
|
@ -30,7 +30,7 @@ export default defineEventHandler(async (event) => { |
|
|
|
setHeader( |
|
|
|
event, |
|
|
|
'Content-Disposition', |
|
|
|
`attachment; filename="${client.name}.conf"` |
|
|
|
`attachment; filename="${encodeURIComponent(client.name)}.conf"` |
|
|
|
); |
|
|
|
setHeader(event, 'Content-Type', 'text/plain'); |
|
|
|
return config; |
|
|
|
|