fix(awooop): cast outbound sent status timestamp gate
All checks were successful
Code Review / ai-code-review (push) Successful in 11s
CD Pipeline / tests (push) Successful in 1m22s
CD Pipeline / build-and-deploy (push) Successful in 3m30s
CD Pipeline / post-deploy-checks (push) Successful in 1m24s

This commit is contained in:
Your Name
2026-05-13 12:12:07 +08:00
parent 971afafc01
commit e57474adfb
3 changed files with 7 additions and 2 deletions

View File

@@ -523,7 +523,7 @@ async def record_outbound_message(
:redaction_version, CAST(:source_envelope AS jsonb),
:provider_message_id,
:send_status, NOW(),
CASE WHEN :send_status = 'sent' THEN NOW() ELSE NULL END,
CASE WHEN CAST(:send_status AS text) = 'sent' THEN NOW() ELSE NULL END,
:triggered_by_state, :waiting_since
)
RETURNING message_id