tree
tree copied to clipboard
Fix human readable output edge cases
Thanks for the PR @james-antill. Can you please add a small test case for this?
Thanks
I added testing, and realized you used KiB format not KB ... so I changed it over to base 10 and created formatBytesKiB(), as you can see that produces output like "1024K" ... if you prefer that, probably just ignore this PR.
Would you consider, perhaps as an option, to include an additional letter i
to get proper unambiguous binary/IEC notation (Ki
, Mi
, Gi
etc)?