cj-upload icon indicating copy to clipboard operation
cj-upload copied to clipboard

Unable to catch error response details

Open bionicvapourboy opened this issue 6 years ago • 2 comments

In Uploader component, in onError prop callback I get as argument of function only one boolean value, instead of full server response (which include validation on additional data sent with files and on the file itself). With only a true/false flag I can't expose to the user the validation error in order to get a valid submission. I am missing somenthing in docs or it is a feature not yet implemented ?

bionicvapourboy avatar May 02 '18 14:05 bionicvapourboy

it should be passing back the response as well: https://github.com/navjobs/upload/blob/master/src/request/register-listeners.js#L21

zackify avatar May 02 '18 22:05 zackify

Will it be better if the response is included in the onError callback parameters. At the moment the response can be only read from the children function of Uploader component.

sd890623 avatar Nov 08 '18 04:11 sd890623