style: Use debug assert instead of a normal assert

This commit is contained in:
timedout authored and Ellis Git committed 2026-04-27 22:15:52 +00:00
1 parent 8575f191a0
commit 0924b7d27e
1 file changed
+6 -3
+6 -3
View File
@@ -9,7 +9,8 @@ use axum_client_ip::ClientIp;
use conduwuit::{
debug, debug_warn, err, error, result::LogErr, state_res::lexicographical_topological_sort, trace,
utils::{
millis_since_unix_epoch, stream::{automatic_width, BroadbandExt, TryBroadbandExt}, IterStream, ReadyExt,
millis_since_unix_epoch, stream::{automatic_width, BroadbandExt, TryBroadbandExt}, IterStream,
ReadyExt,
},
warn,
Err,
@@ -326,11 +327,13 @@ async fn build_local_dag(
Ok((int!(0), MilliSecondsSinceUnixEpoch(ts)))
})
.await
.inspect(|sorted| assert_eq!(
.inspect(|sorted| {
debug_assert_eq!(
sorted.len(),
pdu_map.len(),
"Sorted graph was not the same size as the input graph"
))
);
})
.map_err(|e| err!("failed to resolve local graph: {e}"))
}