From 5b35c69c8e2da2ae8f449c6a2ceffc595b651ae8 Mon Sep 17 00:00:00 2001 From: Noah Vesely Date: Tue, 27 Mar 2018 14:30:50 -0600 Subject: [PATCH] Simplify threshold consistency validation Since the validation already confirms `shares` is not empty, `k_sets` will never match 0. --- src/share/validation.rs | 1 - 1 file changed, 1 deletion(-) diff --git a/src/share/validation.rs b/src/share/validation.rs index 4aa9069..fde5b22 100644 --- a/src/share/validation.rs +++ b/src/share/validation.rs @@ -64,7 +64,6 @@ pub(crate) fn validate_shares(shares: Vec) -> Result<(u8, Vec) let k_sets = k_compatibility_sets.keys().count(); match k_sets { - 0 => bail!(ErrorKind::EmptyShares), 1 => {} // All shares have the same roothash. _ => { bail! {