Changed bytes converter

This commit is contained in:
Jasper Yu 2020-07-09 17:45:13 +08:00
parent 011e3f548c
commit 4861742bc9
1 changed files with 2 additions and 1 deletions

View File

@ -314,7 +314,8 @@ function fmt_rate_axis(num, max) {
function fmt_bytes(bytes) {
if (bytes == undefined) return UNKNOWN_REPR;
return fmt_si_prefix(bytes, bytes, 1024, false) + 'iB';
var prefix = fmt_si_prefix(bytes, bytes, 1024, false);
return prefix + (prefix != bytes ? 'iB' : 'B');
}
function fmt_bytes_axis(num, max) {