Skip to content

Commit

Permalink
Reuse 'Content-Disposition' header value
Browse files Browse the repository at this point in the history
Co-authored-by: Hugo Alliaume <[email protected]>
  • Loading branch information
smnandre and Kocal authored Jan 5, 2025
1 parent 4f6f869 commit 36143e6
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion src/LiveComponent/assets/src/Component/index.ts
Original file line number Diff line number Diff line change
Expand Up @@ -322,7 +322,7 @@ export default class Component {
throw new Error('File is too large to download (10MB limit)');
}

const fileName = headers.get('Content-Disposition')?.split('filename=')[1];
const fileName = headerContentDisposition.split('filename=')[1];
if (!fileName) {
throw new Error('No filename found in Content-Disposition header');
}
Expand Down

0 comments on commit 36143e6

Please sign in to comment.