mirror of
https://github.com/warmbly/warmbly.git
synced 2026-10-27 16:02:28 +00:00
fix: log the reply-intent automation error in HandleNewEmail instead of discarding it with a bare underscore, since a silent failure there is indistinguishable from a reply that linked correctly and leaves nothing anywhere to explain why replied_at stayed NULL while stop_on_reply kept mailing someone who had answered
This commit is contained in:
@@ -93,7 +93,14 @@ func (s *JobsService) HandleNewEmail(ctx context.Context, e *models.JobEventNewE
|
||||
// campaign progress, gating replied_at so automated replies (auto_reply /
|
||||
// out_of_office) never count as a human reply for stop_on_reply / branching.
|
||||
if s.AdvancedService != nil {
|
||||
_ = s.AdvancedService.ProcessIncomingReply(ctx, e.Message.EmailID, e.Message)
|
||||
// Logged, not propagated: the ingest must survive it, but a silent
|
||||
// failure here is indistinguishable from a reply that linked fine.
|
||||
if xerr := s.AdvancedService.ProcessIncomingReply(ctx, e.Message.EmailID, e.Message); xerr != nil {
|
||||
log.Warn().Err(xerr).
|
||||
Str("email_account_id", e.Message.EmailID.String()).
|
||||
Str("message_id", e.Message.MessageID).
|
||||
Msg("Reply-intent automation failed; inbox ingest kept")
|
||||
}
|
||||
}
|
||||
|
||||
return nil
|
||||
|
||||
Reference in New Issue
Block a user