prompt: You will be provided with a partial code base and an issue statement explaining a problem to resolve.
  <issue>
  Fix filter calls
  Similar with the calls to `map`, these calls must be fixed as well.
  
  </issue>
  <code>
  [start of tcms/testplans/helpers/email.py]
  1 # -*- coding: utf-8 -*-
  2 from django.conf import settings
  3 
  4 from tcms.core.utils.mailto import send_email_using_threading
  5 
  6 
  7 def email_plan_update(plan):
  8     recipients = get_plan_notification_recipients(plan)
  9     if len(recipients) == 0:
  10         return
  11     subject = u'TestPlan %s has been updated.' % plan.pk
  12     send_email_using_threading(settings.PLAN_EMAIL_TEMPLATE, subject,
  13                                recipients, {'plan': plan})
  14 
  15 
  16 def email_plan_deletion(plan):
  17     recipients = get_plan_notification_recipients(plan)
  18     if len(recipients) == 0:
  19         return
  20     subject = u'TestPlan %s has been deleted.' % plan.pk
  21     send_email_using_threading(settings.PLAN_DELELE_EMAIL_TEMPLATE, subject,
  22                                recipients, {'plan': plan})
  23 
  24 
  25 def get_plan_notification_recipients(plan):
  26     recipients = set()
  27     if plan.owner:
  28         if plan.email_settings.auto_to_plan_owner:
  29             recipients.add(plan.owner.email)
  30     if plan.email_settings.auto_to_plan_author:
  31         recipients.add(plan.author.email)
  32     if plan.email_settings.auto_to_case_owner:
  33         case_authors = plan.case.values_list('author__email', flat=True)
  34         recipients.update(case_authors)
  35     if plan.email_settings.auto_to_case_default_tester:
  36         case_testers = plan.case.values_list('default_tester__email',
  37                                              flat=True)
  38         recipients.update(case_testers)
  39     return filter(lambda e: bool(e), recipients)
  40
  [end of tcms/testplans/helpers/email.py]
  </code>
  
  I need you to solve this issue by generating a single patch file that I can apply directly to this repository using git apply. Please respond with a single patch file in the following format.
  <patch>
  diff --git a/file.py b/file.py
  --- a/file.py
  +++ b/file.py
  @@ -1,27 +1,35 @@
   def euclidean(a, b):
  -    while b:
  -        a, b = b, a % b
  -    return a
  +    if b == 0:
  +        return a
  +    return euclidean(b, a % b)
   
   
   def bresenham(x0, y0, x1, y1):
       points = []
       dx = abs(x1 - x0)
       dy = abs(y1 - y0)
  -    sx = 1 if x0 < x1 else -1
  -    sy = 1 if y0 < y1 else -1
  -    err = dx - dy
  +    x, y = x0, y0
  +    sx = -1 if x0 > x1 else 1
  +    sy = -1 if y0 > y1 else 1
   
  -    while True:
  -        points.append((x0, y0))
  -        if x0 == x1 and y0 == y1:
  -            break
  -        e2 = 2 * err
  -        if e2 > -dy:
  -            err -= dy
  -            x0 += sx
  -        if e2 < dx:
  -            err += dx
  -            y0 += sy
  +    if dx > dy:
  +        err = dx / 2.0
  +        while x != x1:
  +            points.append((x, y))
  +            err -= dy
  +            if err < 0:
  +                y += sy
  +                err += dx
  +            x += sx
  +    else:
  +        err = dy / 2.0
  +        while y != y1:
  +            points.append((x, y))
  +            err -= dx
  +            if err < 0:
  +                x += sx
  +                err += dy
  +            y += sy
  +
  +    points.append((x, y))
       return points
  
  </patch>
golden_diff: diff --git a/tcms/testplans/helpers/email.py b/tcms/testplans/helpers/email.py
  --- a/tcms/testplans/helpers/email.py
  +++ b/tcms/testplans/helpers/email.py
  @@ -36,4 +36,4 @@
           case_testers = plan.case.values_list('default_tester__email',
                                                flat=True)
           recipients.update(case_testers)
  -    return filter(lambda e: bool(e), recipients)
  +    return [r for r in recipients if r]
  
verification_info: {"golden_diff": "diff --git a/tcms/testplans/helpers/email.py b/tcms/testplans/helpers/email.py\n--- a/tcms/testplans/helpers/email.py\n+++ b/tcms/testplans/helpers/email.py\n@@ -36,4 +36,4 @@\n         case_testers = plan.case.values_list('default_tester__email',\n                                              flat=True)\n         recipients.update(case_testers)\n-    return filter(lambda e: bool(e), recipients)\n+    return [r for r in recipients if r]\n", "issue": "Fix filter calls\nSimilar with the calls to `map`, these calls must be fixed as well.\n", "before_files": [{"content": "# -*- coding: utf-8 -*-\nfrom django.conf import settings\n\nfrom tcms.core.utils.mailto import send_email_using_threading\n\n\ndef email_plan_update(plan):\n    recipients = get_plan_notification_recipients(plan)\n    if len(recipients) == 0:\n        return\n    subject = u'TestPlan %s has been updated.' % plan.pk\n    send_email_using_threading(settings.PLAN_EMAIL_TEMPLATE, subject,\n                               recipients, {'plan': plan})\n\n\ndef email_plan_deletion(plan):\n    recipients = get_plan_notification_recipients(plan)\n    if len(recipients) == 0:\n        return\n    subject = u'TestPlan %s has been deleted.' % plan.pk\n    send_email_using_threading(settings.PLAN_DELELE_EMAIL_TEMPLATE, subject,\n                               recipients, {'plan': plan})\n\n\ndef get_plan_notification_recipients(plan):\n    recipients = set()\n    if plan.owner:\n        if plan.email_settings.auto_to_plan_owner:\n            recipients.add(plan.owner.email)\n    if plan.email_settings.auto_to_plan_author:\n        recipients.add(plan.author.email)\n    if plan.email_settings.auto_to_case_owner:\n        case_authors = plan.case.values_list('author__email', flat=True)\n        recipients.update(case_authors)\n    if plan.email_settings.auto_to_case_default_tester:\n        case_testers = plan.case.values_list('default_tester__email',\n                                             flat=True)\n        recipients.update(case_testers)\n    return filter(lambda e: bool(e), recipients)\n", "path": "tcms/testplans/helpers/email.py"}]}