tus / tus-node-server

Node.js tus server, standalone or integrable in any framework, with disk, S3, and GGC stores.
https://tus.io/
MIT License
795 stars 197 forks source link

@tus/server: allow onUploadFinish hook to override response data #615

Closed netdown closed 3 months ago

netdown commented 4 months ago

Follow-up on #606. Changes based on #599.

changeset-bot[bot] commented 4 months ago

🦋 Changeset detected

Latest commit: 38c3114c5ce3074280f7b4c0162894e483743ae7

The changes in this PR will be included in the next version bump.

This PR includes changesets to release 1 package | Name | Type | | ----------- | ----- | | @tus/server | Minor |

Not sure what this means? Click here to learn what changesets are.

Click here if you're a maintainer who wants to add another changeset to this PR

andreineamtu commented 2 weeks ago

Thank you for the test too! From there I understood that it's important to include the "res" object too so it works! Also that line "If the function returns the (modified) response, the upload will finish." in the README file is very important, but in the latest version is not present anymore. Could you put it back?

Murderlon commented 2 weeks ago

So it wasn't clear that you have to return res in the object? In the next major it will be removed but for now it's needed.