Skip to content

armgit / wger

Public Imported from GitHub
0

Self hosted FLOSS fitness/workout, nutrition and weight tracker

Update management commands

Roland Geiderf614de73013f
diff --git a/wger/core/management/commands/clear-cache.py b/wger/core/management/commands/clear-cache.py
index 1704e8ae5..738618e7c 100644
--- a/wger/core/management/commands/clear-cache.py
+++ b/wger/core/management/commands/clear-cache.py
@@ -58,7 +58,7 @@ class Command(BaseCommand):
help = 'Clears the application cache. You *must* pass an option selecting ' \
'what exactly you want to clear. See available options.'
- def handle(self, *args, **options):
+ def handle(self, **options):
'''
Process the options
'''
diff --git a/wger/core/management/commands/delete-temp-users.py b/wger/core/management/commands/delete-temp-users.py
index 22158f9f2..27e17bc8b 100644
--- a/wger/core/management/commands/delete-temp-users.py
+++ b/wger/core/management/commands/delete-temp-users.py
@@ -28,7 +28,7 @@ class Command(BaseCommand):
help = 'Deletes all temporary users older than 1 week'
- def handle(self, *args, **options):
+ def handle(self, **options):
profile_list = UserProfile.objects.filter(is_temporary=True)
counter = 0
diff --git a/wger/core/management/commands/extract-i18n.py b/wger/core/management/commands/extract-i18n.py
index 748bb3032..d2b370e64 100644
--- a/wger/core/management/commands/extract-i18n.py
+++ b/wger/core/management/commands/extract-i18n.py
@@ -31,7 +31,7 @@ class Command(BaseCommand):
help = 'Read out all strings that have to be included manually in the .po file'
- def handle(self, *args, **options):
+ def handle(self, **options):
# Collect all translatable items
out = []
diff --git a/wger/core/management/commands/update-user-cache.py b/wger/core/management/commands/update-user-cache.py
index b01569b8b..337d8b845 100644
--- a/wger/core/management/commands/update-user-cache.py
+++ b/wger/core/management/commands/update-user-cache.py
@@ -29,7 +29,7 @@ class Command(BaseCommand):
'code used to calculate any of the cached entries is changed and ' \
'the ones in the database need to be updated to reflect the new logic.'
- def handle(self, *args, **options):
+ def handle(self, **options):
'''
Process the options
'''
diff --git a/wger/email/management/commands/send-mass-emails.py b/wger/email/management/commands/send-mass-emails.py
index 2335836e7..658640038 100644
--- a/wger/email/management/commands/send-mass-emails.py
+++ b/wger/email/management/commands/send-mass-emails.py
@@ -26,7 +26,7 @@ class Command(BaseCommand):
Sends the prepared mass emails
'''
- def handle(self, *args, **options):
+ def handle(self, **options):
'''
Send some mails and remove them from the list
'''
diff --git a/wger/exercises/management/commands/download-exercise-images.py b/wger/exercises/management/commands/download-exercise-images.py
index 8e644f501..ff0971401 100644
--- a/wger/exercises/management/commands/download-exercise-images.py
+++ b/wger/exercises/management/commands/download-exercise-images.py
@@ -53,7 +53,7 @@ class Command(BaseCommand):
' their UUID field, if you manually edited or changed it\n'
' the script will not be able to match them.')
- def handle(self, *args, **options):
+ def handle(self, **options):
if not settings.MEDIA_ROOT:
raise ImproperlyConfigured('Please set MEDIA_ROOT in your settings file')
diff --git a/wger/exercises/management/commands/submitted-exercises.py b/wger/exercises/management/commands/submitted-exercises.py
index 84ae13faf..160e28104 100644
--- a/wger/exercises/management/commands/submitted-exercises.py
+++ b/wger/exercises/management/commands/submitted-exercises.py
@@ -27,7 +27,7 @@ class Command(BaseCommand):
help = 'Read out the user submitted exercise'
- def handle(self, *args, **options):
+ def handle(self, **options):
exercises = Exercise.objects.accepted()
usernames = []
diff --git a/wger/gym/management/commands/gym-user-config.py b/wger/gym/management/commands/gym-user-config.py
index 7f7b20f31..e6d64cf25 100644
--- a/wger/gym/management/commands/gym-user-config.py
+++ b/wger/gym/management/commands/gym-user-config.py
@@ -28,7 +28,7 @@ class Command(BaseCommand):
'''
help = 'Check that all gym trainers and users have configurations'
- def handle(self, *args, **options):
+ def handle(self, **options):
'''
Process all users
'''
diff --git a/wger/gym/management/commands/inactive-members.py b/wger/gym/management/commands/inactive-members.py
index baf08f3d7..b72c813a9 100644
--- a/wger/gym/management/commands/inactive-members.py
+++ b/wger/gym/management/commands/inactive-members.py
@@ -34,7 +34,7 @@ class Command(BaseCommand):
'''
help = 'Send out emails to trainers with users that have not shown recent activity'
- def handle(self, *args, **options):
+ def handle(self, **options):
'''
Process gyms and send emails
'''
diff --git a/wger/manager/management/commands/email-reminders.py b/wger/manager/management/commands/email-reminders.py
index ee82d4a52..f5bbbd3f1 100644
--- a/wger/manager/management/commands/email-reminders.py
+++ b/wger/manager/management/commands/email-reminders.py
@@ -35,7 +35,7 @@ class Command(BaseCommand):
help = 'Send out automatic email reminders for workouts'
- def handle(self, *args, **options):
+ def handle(self, **options):
'''
Find if the currently active workout is overdue
'''
diff --git a/wger/weight/management/commands/email-weight-reminder.py b/wger/weight/management/commands/email-weight-reminder.py
index a868c1904..524c20e99 100644
--- a/wger/weight/management/commands/email-weight-reminder.py
+++ b/wger/weight/management/commands/email-weight-reminder.py
@@ -35,7 +35,7 @@ class Command(BaseCommand):
help = 'Send out automatic emails to remind the user to enter the weight'
- def handle(self, *args, **options):
+ def handle(self, **options):
profile_list = UserProfile.objects.filter(num_days_weight_reminder__gt=0)