mirror of
https://github.com/GSA/notifications-admin.git
synced 2026-02-05 10:53:28 -05:00
Added hasattr() back for potential NoneType error
This commit is contained in:
@@ -315,7 +315,7 @@ def init_app(application):
|
||||
def _attach_current_daily_remaining_messages_per_service():
|
||||
remaining_messages = 0
|
||||
|
||||
if current_service:
|
||||
if hasattr(current_service, 'message_limit'):
|
||||
remaining_messages = current_service.message_limit - service_api_client.get_notification_count(
|
||||
service_id=current_service.id)
|
||||
|
||||
|
||||
Reference in New Issue
Block a user