Closed
Description
I am using parse-android SDK 1.13.0. I am able to upload file to parse's backend.
But when i change my server endpoint to migrated end point, upload fails.
{
"code": 130,
"error": "Invalid file upload."
}
I added console logs in file.js on parse-server i found the request.body is empty.
Files.js processCreate req: [object Object] : {} : undefined
var processCreate = function(req, res, next) {
console.log(" Files.js processCreate req:"+req+" : "+ JSON.stringify(req.body)+" : "+req.body.length
if (!req.body || !req.body.length) {
next(new Parse.Error(Parse.Error.FILE_SAVE_ERROR,
'Invalid file upload.'));
return;
}
Exception message shown on client side.
iIllegalStateException: Unable to encode an unsaved ParseFile
Seems to be an issue on the parse-server side. The request body is found empty. I reported this issue on parse-android-sdk. Since the sdk could upload to parse hosted backend. Suspect is on the parse-server side.