mirror of
https://github.com/spalencsar/bearhub.git
synced 2026-07-07 00:04:15 +02:00
[commons.util] refactoring: always strips unit string in 'size_to_byte'
This commit is contained in:
@@ -29,7 +29,7 @@ def deep_update(source: dict, overrides: dict):
|
||||
|
||||
|
||||
def size_to_byte(size: Union[float, int, str], unit: str, logger: Optional[Logger] = None) -> Optional[float]:
|
||||
lower_unit = unit.lower()
|
||||
lower_unit = unit.strip().lower()
|
||||
|
||||
if isinstance(size, str):
|
||||
try:
|
||||
|
||||
Reference in New Issue
Block a user