Skip to content

Commit 7384a65

Browse files
committed
add trace
1 parent cdb1e80 commit 7384a65

File tree

1 file changed

+3
-1
lines changed

1 file changed

+3
-1
lines changed

services/mailer/mail_workflow_run.go

Lines changed: 3 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -41,6 +41,7 @@ func composeAndSendActionsWorkflowRunStatusEmail(ctx context.Context, repo *repo
4141
}
4242
for _, job := range jobs {
4343
if !job.Status.IsDone() {
44+
log.Trace("composeAndSendActionsWorkflowRunStatusEmail: A job is not done. Will not compose and send actions email.")
4445
return
4546
}
4647
}
@@ -122,7 +123,7 @@ func composeAndSendActionsWorkflowRunStatusEmail(ctx context.Context, repo *repo
122123
}
123124
msgs := make([]*sender_service.Message, 0, len(tos))
124125
for _, rec := range tos {
125-
log.Trace("Composing actions email and sending to %s (UID: %d)", rec.Name, rec.ID)
126+
log.Trace("Sending actions email to %s (UID: %d)", rec.Name, rec.ID)
126127
msg := sender_service.NewMessageFrom(
127128
rec.Email,
128129
displayName,
@@ -167,6 +168,7 @@ func MailActionsTrigger(ctx context.Context, sender *user_model.User, repo *repo
167168
}
168169

169170
if len(recipients) > 0 {
171+
log.Trace("MailActionsTrigger: Initiate email composition")
170172
composeAndSendActionsWorkflowRunStatusEmail(ctx, repo, run, sender, recipients)
171173
}
172174
}

0 commit comments

Comments
 (0)