[Update] 修复磁盘显示单位问题

pull/3100/head
ibuler 2019-08-08 17:59:51 +08:00
parent 42ff5a382a
commit fbfbfcc274
1 changed files with 1 additions and 1 deletions

View File

@ -106,7 +106,7 @@ def capacity_convert(size, expect='auto', rate=1000):
if expect == 'auto':
for unit, rate_ in rate_mapping.items():
if rate > std_size/rate_ > 1:
if rate > std_size/rate_ >= 1 or unit == "T":
expect = unit
break