code: def clear_expiration_field_for_expired_jobs(self):
          '''Set the expiration date of every job that has expired.'''
          # Only select rows where there is an expiration date set
          for job in JobPriority.objects.filter(expiration_date__isnull=False):
              if job.has_expired():
                  job.expiration_date = None
                  job.save(f clear_expiration_field_for_expired_jobs(self):
          '''Set the expiration date of every job that has expired.'''
          # Only select rows where there is an expiration date set
          for job in JobPriority.objects.filter(expiration_date__isnull=False):
              if job.has_expired():
                  job.expiration_date = None
                  job.save()
docs: Set the expiration date of every job that has expired.