Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

response undefined in .on('upload-error', (file, error, response) => ...) #5439

Open
2 tasks done
angelaman opened this issue Aug 30, 2024 · 2 comments
Open
2 tasks done
Labels

Comments

@angelaman
Copy link

Initial checklist

  • I understand this is a bug report and questions should be posted in the Community Forum
  • I searched issues and couldn’t find anything (or linked relevant results below)

Link to runnable example

https://stackblitz.com/edit/vitejs-vite-mrjtcx?file=main.js

Steps to reproduce

  1. upload any file
  2. look in the console for message: "Uppy-Error ********************

Expected behavior

In the setup, I added callback on upload error:

.on('upload-error', (file, error, response) => {
    console.log('Uppy-Error ********************', response);
  })

"Uppy-Error ******************** " should be followed with actual response from the http request

Actual behavior

"Uppy-Error ******************** undefined"

undefined is found instead of actual response

@angelaman angelaman added the Bug label Aug 30, 2024
@AxelWerner
Copy link

Same issue here, I hope this can be fixed soon.

@Murderlon
Copy link
Member

How did you actually reproduce this with a real setup? You leave your xhr endpoint empty, if no server exists it's not possible to ever receive a response. Uppy should probably check if endpoint is an empty string and throw and error early.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
Projects
None yet
Development

No branches or pull requests

3 participants