From 8d3aae1d28ee69848e297b6083708b6d85937344 Mon Sep 17 00:00:00 2001 From: Sander Roosendaal Date: Tue, 27 Nov 2018 09:53:09 +0100 Subject: [PATCH] hotfix --- rowers/stravastuff.py | 5 +++-- 1 file changed, 3 insertions(+), 2 deletions(-) diff --git a/rowers/stravastuff.py b/rowers/stravastuff.py index dc131868..aecf3c70 100644 --- a/rowers/stravastuff.py +++ b/rowers/stravastuff.py @@ -175,13 +175,14 @@ def create_async_workout(alldata,user,stravaid,debug=False): except: workouttype = 'other' + if workouttype not in [x[0] for x in Workout.workouttypes]: + workouttype = 'other' + if workouttype.lower() == 'rowing': workouttype = 'rower' if 'summary_polyline' in data['map']: workouttype = 'water' - if workouttype not in [x[0] for x in Workout.workouttypes]: - workouttype = 'other' try: comments = data['comments']