This repository was archived by the owner on Jan 10, 2024. It is now read-only.
This repository was archived by the owner on Jan 10, 2024. It is now read-only.
One extra character in file body after upload using the createBlob() function in forceTK.js #99
Copy link
Copy link
Open
Description
DESCRIPTION:
If we try to upload a new ContentVersion using the createBlob() function in forceTK.js, then an uploaded file will have one extra byte at the end of content body. It will be a "new line" character (LF).
As a result, some uploaded files get corrupted and cannot be recognized by programs if we download them again. For example, MS Excel and MS Word say that such files are incorrect and suggest to fix the issues in format.
SOLUTION:
The issue is in the blob() function (line #293). It adds "\n\n" sequence between payload and final boundary, but only one "\n" is needed.
Metadata
Metadata
Assignees
Labels
No labels