diff --git a/src/engine/dispatch.rs b/src/engine/dispatch.rs index 5dd8140..3ad9f71 100644 --- a/src/engine/dispatch.rs +++ b/src/engine/dispatch.rs @@ -105,7 +105,11 @@ impl Engine { // Announce whatever this command changed to the staff audit channel. out.extend(self.audit_feed(audit_mark, &nick, account.as_deref())); for (cat, text) in alerts { - if let Some(line) = self.feed(&cat, format!("{} {text}", self.who(from))) { + let full = format!("{} {text}", self.who(from)); + // Record to the searchable incident log (OperServ LOGSEARCH) and announce. + let now = self.now_secs(); + self.network.record_incident(format!("[{cat}] {full}"), now); + if let Some(line) = self.feed(&cat, full) { out.push(line); } } diff --git a/src/engine/tests.rs b/src/engine/tests.rs index a81dea5..59f12d5 100644 --- a/src/engine/tests.rs +++ b/src/engine/tests.rs @@ -5552,6 +5552,8 @@ fn confusable_register_alerts_the_staff_feed() { if from == "42SAAAAAO" && to == "#services" && text.contains("[REGISTER]") && text.contains("boss") && text.contains("look-alike"))), "staff feed alert: {out:?}" ); + // ...and it's recorded to the searchable incident log (OperServ LOGSEARCH). + assert!(!e.network.search_incidents("look-alike", 10).is_empty(), "recorded for LOGSEARCH"); } // Perf harness — not part of the normal suite. Run: