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

custom metadata is not working well #354

Closed
ajeecai opened this issue Nov 27, 2021 · 2 comments · Fixed by #355
Closed

custom metadata is not working well #354

ajeecai opened this issue Nov 27, 2021 · 2 comments · Fixed by #355

Comments

@ajeecai
Copy link

ajeecai commented Nov 27, 2021

The code looks like this:
image

When uploading completed, the onComplete callback in server prints:
image

But in some cases, I can see them:

  metadata: [Object: null prototype] {
    ...
   curPath: xxx
   userId: yyy
  },

Is anything wrong?

Thanks

@kukhariev
Copy link
Owner

Hi!
You can see in the first POST request Upload-Metadata header what metadata the client sends (b64 encoded).
Are there curPath and userId fields?

@ajeecai
Copy link
Author

ajeecai commented Nov 28, 2021

Hi @kukhariev , I may find out the reason. In some cases I pass curPath with a null string (stands for root dir), then this looks like unacceptable to the server (built with uploadx/core). From the chrome dev tool, we can see curPath and userId is transferred but server doesn't recognize them:

image

Now I pass curPath as '.' then all works well. If it is regarded as not an issue, please close it.

Thanks

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

Successfully merging a pull request may close this issue.

2 participants