progress-stream
progress-stream copied to clipboard
why length can't be a number?
https://github.com/freeall/progress-stream/blob/1beb155de00a5ee77feb7f422e56e3bec0bcd167/index.js#L67
Yeah this is a bug, but I might be able to explain it. I removed this line and suddenly the progress started tracking properly based on Content Length.
I think the length was expected to be a string due to it coming from Content-Length as a response header. Later in the code I spot a lot of parseInt's that are useless with the progress being a number (maybe only now after NodeJS revisions?).