diff --git a/src/announce.rs b/src/announce.rs index 15c7335..2a25ef1 100644 --- a/src/announce.rs +++ b/src/announce.rs @@ -92,6 +92,18 @@ pub async fn sweep(state: &AppState) -> anyhow::Result<()> { Some(a) => a, }; + // Content is the source of truth while the window is still + // open: a corrected date or place flows into the record, so the + // followup fires on the schedule the page actually announces. + if answer.state == schema.initial && answer.responses != responses { + let mut refreshed = answer.clone(); + refreshed.responses = responses.clone(); + if let Some(store) = &store { + store.put(&id, serde_json::to_vec(&refreshed)?.into()).await?; + tracing::info!(question = %q.id, "event record refreshed from content"); + } + } + if answer.state == schema.initial && now_ms >= ends { let target = "awaiting_summary"; let payload = serde_json::json!({ "to": target, "item": id, "by": "portal" });