Github user jasongin commented on a diff in the pull request:
https://github.com/apache/cordova-plugin-file-transfer/pull/133#discussion_r57474870
--- Diff: src/windows/FileTransferProxy.js ---
@@ -359,7 +359,13 @@ exec(win, fail, 'FileTransfer', 'upload',
if (params.hasOwnProperty(key)) {
var contentPart = new
Windows.Networking.BackgroundTransfer.BackgroundTransferContentPart();
contentPart.setHeader("Content-Disposition",
"form-data; name=\"" + key + "\"");
- contentPart.setText(params[key]);
+ // CreateUploadSync fails when supplied with
empty value for setText function. Pass " " instead when not specified.
+ if (params[key]) {
+ contentPart.setText(params[key]);
+ }
+ else {
+ contentPart.setText(" ");
--- End diff --
Should a null/empty parameter just be omitted from the transfer instead?
---
If your project is set up for it, you can reply to this email and have your
reply appear on GitHub as well. If your project does not have this feature
enabled and wishes so, or if the feature is enabled but not working, please
contact infrastructure at [email protected] or file a JIRA ticket
with INFRA.
---
---------------------------------------------------------------------
To unsubscribe, e-mail: [email protected]
For additional commands, e-mail: [email protected]