Add extension to uploaded debug log
This commit is contained in:
parent
19f8042cd3
commit
51b45ab275
3 changed files with 8 additions and 6 deletions
|
@ -43,9 +43,11 @@ export const uploadDebugLogs = async (
|
|||
const signedForm = await got.get(BASE_URL, { json: true, headers });
|
||||
const { fields, url } = parseTokenBody(signedForm.body);
|
||||
|
||||
const uploadKey = `${fields.key}.gz`;
|
||||
|
||||
const form = new FormData();
|
||||
// The API expects `key` to be the first field:
|
||||
form.append('key', fields.key);
|
||||
form.append('key', uploadKey);
|
||||
Object.entries(fields)
|
||||
.filter(([key]) => key !== 'key')
|
||||
.forEach(([key, value]) => {
|
||||
|
@ -76,5 +78,5 @@ export const uploadDebugLogs = async (
|
|||
}
|
||||
window.log.info('Debug log upload complete.');
|
||||
|
||||
return `${BASE_URL}/${fields.key}`;
|
||||
return `${BASE_URL}/${uploadKey}`;
|
||||
};
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue