diff --git a/src/rest.rs b/src/rest.rs index 00a971df8..fbce52bf2 100644 --- a/src/rest.rs +++ b/src/rest.rs @@ -639,10 +639,13 @@ fn handle_request( TTL_SHORT, ), - (&Method::GET, Some(&"blocks"), start_height, None, None, None) => { - let start_height = start_height.and_then(|height| height.parse::().ok()); - blocks(&query, &config, start_height) + (&Method::GET, Some(&"blocks"), Some(height), None, None, None) => { + blocks(&query, &config, height.parse::().ok()) } + (&Method::GET, Some(&"blocks"), None, None, None, None) => { + blocks(&query, &config, None) + } + (&Method::GET, Some(&"block-height"), Some(height), None, None, None) => { let height = height.parse::()?; let header = query