fix(rpc): validate toBlock in trace_filter (#21718)

This commit is contained in:
drhgencer
2026-02-03 16:32:57 +05:30
committed by GitHub
parent ee224fe20f
commit e04afe6e0e

View File

@@ -353,6 +353,9 @@ where
return Err(EthApiError::HeaderNotFound(start.into()).into());
}
let end = to_block.unwrap_or(latest_block);
if end > latest_block {
return Err(EthApiError::HeaderNotFound(end.into()).into());
}
if start > end {
return Err(EthApiError::InvalidParams(