Private
Public Access
1
0

Merge branch 'hotfix/v7.16'

This commit is contained in:
Sander Roosendaal
2018-07-06 16:34:52 +02:00
+4 -1
View File
@@ -918,7 +918,7 @@ def hasplannedsessions(user):
result = user.is_authenticated() and (r.rowerplan=='coach' or r.rowerplan=='plan') result = user.is_authenticated() and (r.rowerplan=='coach' or r.rowerplan=='plan')
if not result and r.plantrialexpires: if not result and r.plantrialexpires:
result = user.is_authenticaded() and r.rowerplan=='basic' and r.plantrialexpires >= datetime.date.today() result = user.is_authenticated() and r.rowerplan=='basic' and r.plantrialexpires >= datetime.date.today()
else: else:
result = False result = False
@@ -11333,7 +11333,10 @@ def workout_summary_edit_view(request,id,message="",successmessage=""
work = int(normw) work = int(normw)
power = int(normp) power = int(normp)
try:
pace_secs = int(500./normv) pace_secs = int(500./normv)
except (OverflowError, ZeroDivisionError):
pace_secs = 140.
try: try:
avpace = datetime.timedelta(seconds=int(500./normv)) avpace = datetime.timedelta(seconds=int(500./normv))