You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
Hi,
I'm looking at your library to parse the range http header.
And I was wondering why you are making the size a required field, even though it is not part of the header.
A range is supposed to be like this:
Or do you mean that in order to parse the range, the server should get the size of the file, given that he will need it to correctly format the content-range header in the response.
The text was updated successfully, but these errors were encountered:
Hi @nicolasroger17 unfortunately the original author is no longer around, and I don't know the reasoning to why the current API. There are certainly a lot of folks using the current API, though that doesn't mean it cannot be changed with a major version bump (and usually assessing what it would change in the existing uses so a migration doc can be written up).
Sorry I don't have the answer for you. Since it' been a few months, it is unlikely the author will answer your question, so I don't want to just leave your issue open indefinately.
Or do you mean that in order to parse the range, the server should get the size of the file, given that he will need it to correctly format the content-range header in the response.
Correct: "[...] where size is the maximum size of the resource." 👍
Hi,
I'm looking at your library to parse the
range
http header.And I was wondering why you are making the
size
a required field, even though it is not part of the header.A range is supposed to be like this:
https://developer.mozilla.org/en-US/docs/Web/HTTP/Headers/Range
I've tried to go around it by setting size to
Infinity
, but then when I use this format of header:then it returns
end: Infinity
instead of null.I've read the comment here: https://github.com/expressjs/express/blob/b97faff6e2aa4d34d79485fe4331cb0eec13ad57/lib/request.js#L188
But if you look at these simple examples:
https://stackoverflow.com/questions/8293687/sample-http-range-request-session#answer-8507991
The client is only sending the
range
, without anycontent-length
.Or do you mean that in order to parse the
range
, the server should get thesize
of the file, given that he will need it to correctly format thecontent-range
header in the response.The text was updated successfully, but these errors were encountered: