Commit d44fa693 authored by Gabriel Dengler's avatar Gabriel Dengler
Browse files

Fixing calculation of average

parent 2136db26
[Unit]
Description=Campusscraper
After=network.target
StartLimitIntervalSec=0
[Service]
Type=simple
Restart=always
RestartSec=1
User=chief
Group=chief
WorkingDirectory=/home/chief/campusscraper/
ExecStart=/home/chief/campusscraper/env/bin/python telegram_bot.py autostart
KillSignal=SIGINT
[Install]
WantedBy=multi-user.target
......@@ -175,8 +175,11 @@ def read_module_properties(module):
except ValueError:
pass
grade = grade_ects/this_ects
grade = '{:.1f}'.format(grade).replace('.', ',')
if this_ects != 0:
grade = grade_ects/this_ects
grade = '{:.1f}'.format(grade).replace('.', ',')
else:
grade = '-/-'
if not ects:
ects = 0
......
Supports Markdown
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment