Skip to content

The fastest, cheapest, most efficient open-source agent harness. Run more than 500 agents on a $10 VPS.

fix(debug): use is_multiple_of for thousands separator logic

Steven Enamakel1cdf120bfd45
diff --git a/src/openhuman/agent/debug/wire.rs b/src/openhuman/agent/debug/wire.rs
index 697265f546..8d5ca20e0a 100644
--- a/src/openhuman/agent/debug/wire.rs
+++ b/src/openhuman/agent/debug/wire.rs
@@ -48,7 +48,7 @@ fn thousands(n: usize) -> String {
let s = n.to_string();
let mut out = String::with_capacity(s.len() + s.len() / 3);
for (i, c) in s.chars().enumerate() {
- if i > 0 && (s.len() - i) % 3 == 0 {
+ if i > 0 && (s.len() - i).is_multiple_of(3) {
out.push(',');
}
out.push(c);