Skip to content

Commit

Permalink
Merge pull request #151 from input-output-hk/update-chain-libs
Browse files Browse the repository at this point in the history
update to chain-libs with new lints applied
  • Loading branch information
eugene-babichenko committed May 12, 2021
2 parents f158719 + e22b4ad commit 1bcbc1f
Show file tree
Hide file tree
Showing 2 changed files with 4 additions and 4 deletions.
6 changes: 3 additions & 3 deletions bindings/wallet-core/src/c/vote.rs
Original file line number Diff line number Diff line change
Expand Up @@ -103,12 +103,12 @@ mod tests {

#[test]
fn cast_private_vote() {
use chain_vote::gargamel;
use chain_vote::encryption;
use rand::SeedableRng;
let vote_plan_id = [0u8; crate::vote::VOTE_PLAN_ID_LENGTH];
let mut rng = rand_chacha::ChaCha20Rng::from_seed([1u8; 32]);
let sk = gargamel::SecretKey::generate(&mut rng);
let pk = gargamel::Keypair::from_secretkey(sk).public_key;
let sk = encryption::SecretKey::generate(&mut rng);
let pk = encryption::Keypair::from_secretkey(sk).public_key;

let encrypting_vote_key =
bech32::encode(ENCRYPTION_VOTE_KEY_HRP, pk.to_bytes().to_base32()).unwrap();
Expand Down
2 changes: 1 addition & 1 deletion bindings/wallet-core/src/vote.rs
Original file line number Diff line number Diff line change
Expand Up @@ -79,7 +79,7 @@ impl Proposal {
let vote = Vote::new(length.into(), choice.into());
let (encrypted_vote, proof) = vote::encrypt_vote(
&mut rng,
&chain_vote::CRS::from_hash(self.vote_plan_id.as_ref()),
&chain_vote::Crs::from_hash(self.vote_plan_id.as_ref()),
key,
vote,
);
Expand Down

0 comments on commit 1bcbc1f

Please sign in to comment.