Closed YuryShkoda closed 1 year ago
Because typeof FormData is function for node and browser environments, it is right to compare it to undefined.
FormData
function
undefined
Fix sending form data to /SASLogon/oauth/token endpoint in order to refresh access token.
/SASLogon/oauth/token
isNode utility is used to check if the environment is node to use a correct instance of FormData from form-data package.
isNode
node
form-data
No PR (that involves a non-trivial code change) should be merged, unless all items below are confirmed! If an urgent fix is needed - use a tar file.
sasjs-cli
npm test
sasjs-tests
Issue
Because typeof
FormData
isfunction
for node and browser environments, it is right to compare it toundefined
.Intent
Fix sending form data to
/SASLogon/oauth/token
endpoint in order to refresh access token.Implementation
isNode
utility is used to check if the environment isnode
to use a correct instance ofFormData
fromform-data
package.Checks
No PR (that involves a non-trivial code change) should be merged, unless all items below are confirmed! If an urgent fix is needed - use a tar file.
sasjs-cli
unit tests are passing (npm test
).sasjs-tests
are passing. If you want to run it manually (instructions available here).