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

Add test and improve docs for progress.total #924

Closed
1 of 3 tasks
sindresorhus opened this issue Nov 7, 2019 · 0 comments · Fixed by #1061
Closed
1 of 3 tasks

Add test and improve docs for progress.total #924

sindresorhus opened this issue Nov 7, 2019 · 0 comments · Fixed by #1061
Labels
documentation The issue will improve the docs enhancement This change will extend Got features ✭ help wanted ✭

Comments

@sindresorhus
Copy link
Owner

sindresorhus commented Nov 7, 2019

The docs says:

If it's not possible to retrieve the body size (can happen when streaming), total will be null. - https://github.com/sindresorhus/got#ondownloadprogress-progress

But we have no tests to prove this.

  • Add test
  • Be more specific than "can happen when streaming". In what exact scenarios can it happen?
  • Make it undefined instead of null
@szmarczak szmarczak added enhancement This change will extend Got features ✭ help wanted ✭ labels Nov 7, 2019
@szmarczak szmarczak added the documentation The issue will improve the docs label Nov 24, 2019
This was referenced Feb 6, 2020
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
documentation The issue will improve the docs enhancement This change will extend Got features ✭ help wanted ✭
Projects
None yet
Development

Successfully merging a pull request may close this issue.

2 participants