tus-node-server icon indicating copy to clipboard operation
tus-node-server copied to clipboard

Sanitize file URLs

Open OzTK opened this issue 2 years ago • 0 comments

The current behaviour is creating a bad file url when the path is set to the root:

    server.datastore = new tus.FileStore({
      path: '/'
    })

results in a URL of the form http://localhost//12334456

This sanitizes the constructed url when posting the download so that it results in a valid URL for the created file. Trimming was added as well.

OzTK avatar Jun 15 '22 23:06 OzTK