Skip to content

Commit

Permalink
Case assignee check fails faster.
Browse files Browse the repository at this point in the history
  • Loading branch information
metroid-samus committed Nov 20, 2023
1 parent 20d49a5 commit ca83cc2
Showing 1 changed file with 4 additions and 4 deletions.
8 changes: 4 additions & 4 deletions src/dispatch/case/messaging.py
Original file line number Diff line number Diff line change
Expand Up @@ -68,6 +68,10 @@ def send_case_triage_reminder(case: Case, db_session: SessionLocal):
log.warning("Case triage reminder message not sent. No conversation plugin enabled.")
return

if not case.assignee:
log.warning("Case triage reminder message not sent. No assignee.")
return

items = [
{
"name": case.name,
Expand All @@ -77,10 +81,6 @@ def send_case_triage_reminder(case: Case, db_session: SessionLocal):
}
]

if not case.assignee:
log.warning("Case triage reminder message not sent. No assignee.")
return

plugin.instance.send_direct(
case.assignee.individual.email,
message_text,
Expand Down

0 comments on commit ca83cc2

Please sign in to comment.