Private
Public Access
1
0

Merge branch 'release/v18.0.14'

This commit is contained in:
Sander Roosendaal
2023-03-25 15:16:37 +01:00
2 changed files with 13 additions and 2 deletions

Binary file not shown.

View File

@@ -409,8 +409,19 @@ def workout_import_view(request, source='c2'):
after = arrow.get(startdate)
after = str(int(after.timestamp()*1000))
workouts = integration.get_workout_list(before=before, after=after, startdate=startdate, enddate=enddate)
try:
workouts = integration.get_workout_list(
before=before,
after=after,
startdate=startdate,
enddate=enddate
)
except NoTokenError:
messages.error(request,"You must first make the connection to {source}".format(
source=source
))
url = reverse(importauthorizeviews[source],kwargs={'source':source})
return HttpResponseRedirect(url)
if request.method == 'POST': # pragma: no cover
try: