bug fix
This commit is contained in:
@@ -1085,6 +1085,9 @@ def save_workout_database(f2, r, dosmooth=True, workouttype='rower',
|
||||
impeller=False):
|
||||
|
||||
message = None
|
||||
if title is None:
|
||||
title = 'Workout'
|
||||
|
||||
powerperc = 100 * np.array([r.pw_ut2,
|
||||
r.pw_ut1,
|
||||
r.pw_at,
|
||||
@@ -1280,7 +1283,7 @@ def save_workout_database(f2, r, dosmooth=True, workouttype='rower',
|
||||
duplicate = True
|
||||
|
||||
# test title length
|
||||
if len(title)>140:
|
||||
if title is not None and len(title)>140:
|
||||
title = title[0:140]
|
||||
|
||||
w = Workout(user=r, name=title, date=workoutdate,
|
||||
|
||||
Reference in New Issue
Block a user