mirror of
https://github.com/sigp/lighthouse.git
synced 2026-03-15 19:02:42 +00:00
Allow 1 count block request to return 0 blocks (#5554)
* Allow 1 count block request to return 0 blocks * Address @pawanjay176 review
This commit is contained in:
@@ -654,8 +654,8 @@ pub enum InboundRequest<E: EthSpec> {
|
||||
impl<E: EthSpec> InboundRequest<E> {
|
||||
/* These functions are used in the handler for stream management */
|
||||
|
||||
/// Number of responses expected for this request.
|
||||
pub fn expected_responses(&self) -> u64 {
|
||||
/// Maximum number of responses expected for this request.
|
||||
pub fn max_responses(&self) -> u64 {
|
||||
match self {
|
||||
InboundRequest::Status(_) => 1,
|
||||
InboundRequest::Goodbye(_) => 0,
|
||||
|
||||
Reference in New Issue
Block a user