diff --git a/lighthouse/state/attestation_record/validation/signature_verification.rs b/lighthouse/state/attestation_record/validation/signature_verification.rs index 165b03fe7..c33dc2806 100644 --- a/lighthouse/state/attestation_record/validation/signature_verification.rs +++ b/lighthouse/state/attestation_record/validation/signature_verification.rs @@ -48,7 +48,8 @@ pub fn verify_aggregate_signature_for_indices( /* * Load the validators public key from our store. */ - let pub_key = validator_store.get_public_key_by_index(i)? + let pub_key = validator_store + .get_public_key_by_index(validator)? .ok_or(SignatureVerificationError::NoPublicKeyForValidator)?; /* * Add the validators public key to the aggregate public key.