Skip to content

Commit

Permalink
Remove unused error variant.
Browse files Browse the repository at this point in the history
  • Loading branch information
Neopallium committed Nov 21, 2024
1 parent 2661b80 commit d3cc12d
Show file tree
Hide file tree
Showing 2 changed files with 5 additions and 3 deletions.
7 changes: 5 additions & 2 deletions rust/frameworks/tw_substrate/src/entry.rs
Original file line number Diff line number Diff line change
Expand Up @@ -43,8 +43,11 @@ impl<T: SubstrateCoinEntry> SubstrateEntry<T> {
coin: &dyn CoinContext,
input: T::SigningInput<'_>,
) -> SigningResult<RawOwned> {
let keypair = self.0.get_keypair(coin, &input).ok();
let public_key = keypair.map(|p| p.public().clone());
let public_key = self
.0
.get_keypair(coin, &input)
.ok()
.map(|p| p.public().clone());
let unsigned_tx = self.0.build_transaction(coin, public_key, &input)?;
let pre_image = unsigned_tx.encode_payload()?;
Ok(RawOwned(pre_image))
Expand Down
1 change: 0 additions & 1 deletion rust/frameworks/tw_substrate/src/lib.rs
Original file line number Diff line number Diff line change
Expand Up @@ -23,7 +23,6 @@ pub enum EncodeError {
InvalidCallIndex,
InvalidAddress,
InvalidValue,
MissingPrivateKey,
}

impl From<EncodeError> for SigningError {
Expand Down

0 comments on commit d3cc12d

Please sign in to comment.