mirror of
https://github.com/GSA/notifications-api.git
synced 2025-12-20 07:21:13 -05:00
flake8 - misc flake8 errs.
* unused variables * variables in loops overshadowing imports * excepts with no defined exc type (tried to avoid `except Exception` too) * history mapper is still too complex * default variables should never be mutable
This commit is contained in:
@@ -7,7 +7,9 @@ from app.models import EMAIL_TYPE, KEY_TYPE_NORMAL
|
||||
from app.notifications.process_notifications import persist_notification, send_notification_to_queue
|
||||
|
||||
|
||||
def send_notification_to_service_users(service_id, template_id, personalisation={}, include_user_fields=[]):
|
||||
def send_notification_to_service_users(service_id, template_id, personalisation=None, include_user_fields=None):
|
||||
personalisation = personalisation or {}
|
||||
include_user_fields = include_user_fields or []
|
||||
template = dao_get_template_by_id(template_id)
|
||||
service = dao_fetch_service_by_id(service_id)
|
||||
active_users = dao_fetch_active_users_for_service(service.id)
|
||||
|
||||
Reference in New Issue
Block a user