🔀 Merge pull request #105 from iuriguilherme/master
We shall not divide by zero
This commit is contained in:
commit
ff2e627967
2 changed files with 2 additions and 1 deletions
|
@ -7,6 +7,7 @@
|
|||
The following wonderful people contributed directly or indirectly to this project:
|
||||
|
||||
- [imlonghao](https://github.com/imlonghao)
|
||||
- [Iuri Guilherme](https://github.com/iuriguilherme)
|
||||
- [pan93412](https://github.com/pan93412)
|
||||
- [qubitnerd](https://github.com/qubitnerd)
|
||||
- [SYHGroup](https://github.com/SYHGroup)
|
||||
|
|
|
@ -126,7 +126,7 @@ def stats(bot, update):
|
|||
)
|
||||
|
||||
n = us.first_places
|
||||
m = round((us.first_places / us.games_played) * 100)
|
||||
m = round((us.first_places / us.games_played) * 100) if us.games_played else 0
|
||||
stats_text.append(
|
||||
_("{number} first place ({percent}%)",
|
||||
"{number} first places ({percent}%)",
|
||||
|
|
Loading…
Reference in a new issue