Skip to content

Commit f1d7da1

Browse files
authored
Merge pull request #763 from topcoder-platform/CORE-100
update file service request body
2 parents 140cd24 + 332cbc0 commit f1d7da1

File tree

1 file changed

+3
-3
lines changed

1 file changed

+3
-3
lines changed

src/services/fileService.js

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -6,7 +6,7 @@ const getDownloadUrl = async (bucket, key) => {
66
const token = await util.getM2MToken();
77
const { data } = await axios.post(
88
`${config.get('fileServiceEndpoint')}/downloadurl`,
9-
{ Bucket: bucket, Key: key },
9+
{ bucket, key },
1010
{ headers: { Authorization: `Bearer ${token}` } },
1111
);
1212
return data.url;
@@ -16,7 +16,7 @@ const getUploadUrl = async (bucket, key) => {
1616
const token = await util.getM2MToken();
1717
const { data } = await axios.post(
1818
`${config.get('fileServiceEndpoint')}/uploadurl`,
19-
{ Bucket: bucket, Key: key },
19+
{ bucket, key },
2020
{ headers: { Authorization: `Bearer ${token}` } },
2121
);
2222
return data.url;
@@ -26,7 +26,7 @@ const deleteFile = async (bucket, key) => {
2626
const token = await util.getM2MToken();
2727
await axios.post(
2828
`${config.get('fileServiceEndpoint')}/deletefile`,
29-
{ Bucket: bucket, Key: key },
29+
{ bucket, key },
3030
{ headers: { Authorization: `Bearer ${token}` } },
3131
);
3232
};

0 commit comments

Comments
 (0)