Skip to content

Commit

Permalink
fixup! feat: add trezor support for VP delegation
Browse files Browse the repository at this point in the history
  • Loading branch information
szymonmaslowski committed Nov 27, 2024
1 parent c01f2f5 commit f55834d
Showing 1 changed file with 4 additions and 2 deletions.
6 changes: 4 additions & 2 deletions source/renderer/app/utils/shelleyTrezor.ts
Original file line number Diff line number Diff line change
Expand Up @@ -67,16 +67,18 @@ const parseVoteDelegation = (cert: CoinSelectionCertificate): CardanoDRep => {
};
}

const voteHash = utils.bech32_decodeAddress(cert.vote).toString('hex');

if (cert.vote.includes('_script')) {
return {
type: PROTO.CardanoDRepType.SCRIPT_HASH,
scriptHash: cert.vote,
scriptHash: voteHash,
};
}

return {
type: PROTO.CardanoDRepType.KEY_HASH,
keyHash: cert.vote,
keyHash: voteHash,
};
};

Expand Down

0 comments on commit f55834d

Please sign in to comment.