Skip to content

Commit

Permalink
fix: decimal bug
Browse files Browse the repository at this point in the history
  • Loading branch information
Tanguy-Boisset committed Nov 17, 2023
1 parent cba881a commit 209a7bb
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion ad_miner/sources/modules/smolcard_class.py
Expand Up @@ -208,7 +208,7 @@ def render(self, page_f, return_html=False):
percent = "%"
width_evolution_big = 9
try:
evolution_percent = abs(round((evolution_chart_data[-1] - evolution_chart_data[-2]) / evolution_chart_data[-2], 3) * 100)
evolution_percent = abs(round((evolution_chart_data[-1] - evolution_chart_data[-2]) / evolution_chart_data[-2] *100, 1))
except ZeroDivisionError:
# If the stats staggers at zero, it's a great thing
if evolution_chart_data[-1] == 0:
Expand Down

0 comments on commit 209a7bb

Please sign in to comment.