excluding basic users from auto sync
This commit is contained in:
@@ -145,6 +145,8 @@ def get_polar_notifications():
|
||||
|
||||
return available_data
|
||||
|
||||
from rowers.utils import isprorower
|
||||
|
||||
def get_all_new_workouts(available_data,testing=False):
|
||||
for record in available_data:
|
||||
if testing:
|
||||
@@ -153,7 +155,7 @@ def get_all_new_workouts(available_data,testing=False):
|
||||
try:
|
||||
r = Rower.objects.get(polaruserid=record['user-id'])
|
||||
u = r.user
|
||||
if r.polar_auto_import:
|
||||
if r.polar_auto_import and isprorower(r):
|
||||
exercise_list = get_polar_workouts(u)
|
||||
if testing:
|
||||
print exercise_list
|
||||
|
||||
Reference in New Issue
Block a user