Skip to content

Commit

Permalink
Suggested change
Browse files Browse the repository at this point in the history
  • Loading branch information
bieniu committed Mar 4, 2024
1 parent 81bd673 commit 0718256
Showing 1 changed file with 2 additions and 2 deletions.
4 changes: 2 additions & 2 deletions tools/common/__init__.py
Original file line number Diff line number Diff line change
Expand Up @@ -104,11 +104,11 @@ def print_block_device(device: BlockDevice) -> None:
info = block.info(attr)

if value is None:
value = "-" # noqa: PLW2901
_value = value if value is not None else "-"

unit = " " + info[BLOCK_VALUE_UNIT] if BLOCK_VALUE_UNIT in info else ""

print(f"{attr.ljust(16)}{value}{unit}")
print(f"{attr.ljust(16)}{_value}{unit}")
print()


Expand Down

0 comments on commit 0718256

Please sign in to comment.