diff --git a/LaundryTracker/wsgi.py b/LaundryTracker/wsgi.py index 6c6ea2a..2a26161 100644 --- a/LaundryTracker/wsgi.py +++ b/LaundryTracker/wsgi.py @@ -14,6 +14,11 @@ # Import and run the command from django.core.management import call_command -call_command('clear_old_tasks') + +try: + call_command('clear_old_tasks') +except Exception as e: + print(e) + print('Failed to clear old tasks') application = get_wsgi_application() \ No newline at end of file