From 8e38f90e546811339e1e0ec2234a329753f38b83 Mon Sep 17 00:00:00 2001 From: "mergify[bot]" <37929162+mergify[bot]@users.noreply.github.com> Date: Wed, 20 Jan 2021 22:48:32 +0000 Subject: [PATCH] Default to highest finalized block if no slot provided (#14701) (#14704) (cherry picked from commit c64d4f76939415374f83a2001f4dc0e1067409d3) Co-authored-by: Tyera Eulberg --- cli/src/cluster_query.rs | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/cli/src/cluster_query.rs b/cli/src/cluster_query.rs index ab6181abe8..47eba6b697 100644 --- a/cli/src/cluster_query.rs +++ b/cli/src/cluster_query.rs @@ -880,7 +880,7 @@ pub fn process_get_block( let slot = if let Some(slot) = slot { slot } else { - rpc_client.get_slot()? + rpc_client.get_slot_with_commitment(CommitmentConfig::max())? }; let mut block = @@ -958,7 +958,7 @@ pub fn process_get_block_time( let slot = if let Some(slot) = slot { slot } else { - rpc_client.get_slot()? + rpc_client.get_slot_with_commitment(CommitmentConfig::max())? }; let timestamp = rpc_client.get_block_time(slot)?; let block_time = CliBlockTime { slot, timestamp };