Skip to content

Commit

Permalink
File download - removed unnecesary encoding on file key (#1879)
Browse files Browse the repository at this point in the history
  • Loading branch information
GPaoloni authored Nov 27, 2023
1 parent 55e87a5 commit 661c316
Showing 1 changed file with 1 addition and 2 deletions.
3 changes: 1 addition & 2 deletions plugin-hrm-form/src/components/common/forms/DownloadFile.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -46,7 +46,6 @@ const DownloadFile: React.FC<Props> = ({ fileNameAtAws, targetObject }) => {

const handleClick = async () => {
const { docsBucket: bucket } = getHrmConfig();
const key = encodeURIComponent(fileNameAtAws);

try {
const { media_url: preSignedUrl } = await fetchHrmApi(
Expand All @@ -57,7 +56,7 @@ const DownloadFile: React.FC<Props> = ({ fileNameAtAws, targetObject }) => {
fileType: 'document',
location: {
bucket,
key,
key: fileNameAtAws,
},
}),
);
Expand Down

0 comments on commit 661c316

Please sign in to comment.