From f364bdadb8671d18f1ef2b22d120c62cc263c9b9 Mon Sep 17 00:00:00 2001 From: Thibault Martinez Date: Wed, 13 Sep 2023 14:58:56 +0200 Subject: [PATCH] UnexpectedBlockKind nit --- sdk/src/client/api/high_level.rs | 2 +- sdk/src/client/error.rs | 4 ++-- sdk/src/wallet/account/operations/syncing/outputs.rs | 2 +- 3 files changed, 4 insertions(+), 4 deletions(-) diff --git a/sdk/src/client/api/high_level.rs b/sdk/src/client/api/high_level.rs index 8f14a42547..f2ae1a010a 100644 --- a/sdk/src/client/api/high_level.rs +++ b/sdk/src/client/api/high_level.rs @@ -46,8 +46,8 @@ impl Client { self.get_outputs_with_metadata(&input_ids).await } else { Err(Error::UnexpectedBlockKind { - actual: wrapper.block().kind(), expected: BasicBlock::KIND, + actual: wrapper.block().kind(), }) } } diff --git a/sdk/src/client/error.rs b/sdk/src/client/error.rs index 4c285afe5a..d78ed8dc42 100644 --- a/sdk/src/client/error.rs +++ b/sdk/src/client/error.rs @@ -161,8 +161,8 @@ pub enum Error { #[error("missing BIP32 chain to sign with")] MissingBip32Chain, /// Unexpected block kind. - #[error("unexpected block kind, got {actual}, expected {expected}")] - UnexpectedBlockKind { actual: u8, expected: u8 }, + #[error("unexpected block kind: expected {expected}, found {actual}")] + UnexpectedBlockKind { expected: u8, actual: u8 }, /// Missing transaction payload. #[error("missing transaction payload")] MissingTransactionPayload, diff --git a/sdk/src/wallet/account/operations/syncing/outputs.rs b/sdk/src/wallet/account/operations/syncing/outputs.rs index b8d08b0cef..c97cf594f2 100644 --- a/sdk/src/wallet/account/operations/syncing/outputs.rs +++ b/sdk/src/wallet/account/operations/syncing/outputs.rs @@ -164,8 +164,8 @@ where } } else { Err(ClientError::UnexpectedBlockKind { - actual: wrapper.block().kind(), expected: BasicBlock::KIND, + actual: wrapper.block().kind(), } .into()) }