Refactor: Rename method and parameter

This commit is contained in:
Manfred Karrer 2019-04-05 20:16:12 -05:00
parent 400fbbd080
commit 5cfa2c77ac
No known key found for this signature in database
GPG key ID: 401250966A6B2C46
2 changed files with 3 additions and 3 deletions

View file

@ -95,8 +95,8 @@ public class BlindVoteConsensus {
return Encryption.encrypt(bytes, secretKey);
}
public static byte[] getHashOfEncryptedProposalList(byte[] encryptedProposalList) {
return Hash.getSha256Ripemd160hash(encryptedProposalList);
public static byte[] getHashOfEncryptedVotes(byte[] encryptedVotes) {
return Hash.getSha256Ripemd160hash(encryptedVotes);
}
public static byte[] getOpReturnData(byte[] hash) throws IOException {

View file

@ -261,7 +261,7 @@ public class MyBlindVoteListService implements PersistedDataHost, DaoStateListen
private byte[] getOpReturnData(byte[] encryptedVotes) throws IOException {
// We cannot use hash of whole blindVote data because we create the merit signature with the blindVoteTxId
// So we use the encryptedVotes for the hash only.
final byte[] hash = BlindVoteConsensus.getHashOfEncryptedProposalList(encryptedVotes);
final byte[] hash = BlindVoteConsensus.getHashOfEncryptedVotes(encryptedVotes);
log.info("Sha256Ripemd160 hash of encryptedVotes: " + Utilities.bytesAsHexString(hash));
return BlindVoteConsensus.getOpReturnData(hash);
}