From 710701d0fce7a2b968ce933c9b21a71708b7ed5c Mon Sep 17 00:00:00 2001 From: Daniel Gasienica Date: Wed, 7 Mar 2018 14:50:32 -0500 Subject: [PATCH] Document why `key` comes first --- js/modules/debuglogs.js | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/js/modules/debuglogs.js b/js/modules/debuglogs.js index a753f104d..f7173af43 100644 --- a/js/modules/debuglogs.js +++ b/js/modules/debuglogs.js @@ -26,8 +26,8 @@ exports.upload = async (content) => { const { fields, url } = signedForm.body; const form = new FormData(); + // The API expects `key` to be the first field: form.append('key', fields.key); - Object.entries(fields) .filter(([key]) => key !== 'key') .forEach(([key, value]) => {