Skip to content

Commit

Permalink
use x
Browse files Browse the repository at this point in the history
  • Loading branch information
bernt-matthias committed Feb 19, 2024
1 parent 73708f9 commit 22f5073
Showing 1 changed file with 4 additions and 4 deletions.
8 changes: 4 additions & 4 deletions lib/galaxy/util/__init__.py
Original file line number Diff line number Diff line change
Expand Up @@ -1144,9 +1144,9 @@ def trailing_zeros_to_powerof10(amount: int):
>>> trailing_zeros_to_powerof10(23000)
'23000'
>>> trailing_zeros_to_powerof10(2300000)
'23\u22C510^5'
'23\u00d710^5'
>>> trailing_zeros_to_powerof10(23000000)
'23\u22C510^6'
'23\u00d710^6'
>>> trailing_zeros_to_powerof10(1)
'1'
>>> trailing_zeros_to_powerof10(0)
Expand All @@ -1162,10 +1162,10 @@ def trailing_zeros_to_powerof10(amount: int):
while i >= 0 and amount[i] == "0":
zeros += 1
i -= 1
if len(amount) < len(f"{amount[: i+1]}\u22C510^{zeros}"):
if len(amount) < len(f"{amount[: i+1]}\u00d710^{zeros}"):
return amount
else:
return f"{amount[: i+1]}\u22C510^{zeros}"
return f"{amount[: i+1]}\u00d710^{zeros}"


def roundify(amount: int, sfs: int = 2):
Expand Down

0 comments on commit 22f5073

Please sign in to comment.