NativeScript / nativescript-background-http

Background Upload plugin for the NativeScript framework
Apache License 2.0
102 stars 50 forks source link

response code is 200 but nothing uploaded and result has no data #229

Closed aattia346 closed 5 years ago

aattia346 commented 5 years ago

in session.uploadFile(fileUri, request) it responds with 200 but data is empty here is the response:

{ JS: "eventName": "responded", JS: "object": { JS: "_observers": { JS: "progress": [ JS: {} JS: ], JS: "error": [ JS: {} JS: ], JS: "responded": [ JS: {} JS: ], JS: "complete": [ JS: {} JS: ] JS: }, JS: "_session": { JS: "_id": "image-upload" JS: }, JS: "_id": "image-upload{1}", JS: "_description": "Uploading file", JS: "_upload": 11243, JS: "_totalUpload": 11243, JS: "_status": "complete" JS: }, JS: "data": "{\"result\":{\"files\":{},\"fields\":{}}}", JS: "responseCode": 200 JS: }

DimitarTodorov commented 5 years ago

Hi @aattia346 The plugin provides a functionality to upload files to a server. The request you are posting here is about server functionality. You have to implement a functionality on your server which fills the data of the response. Another way is to add an endpoint of your server in order to call it and observe the desired information. Regards, NativeScript Team