Skip to content

Commit 6cb3b8d

Browse files
committed
fix: format
Signed-off-by: bkioshn <[email protected]>
1 parent 3a9f170 commit 6cb3b8d

File tree

1 file changed

+7
-6
lines changed
  • rust/rbac-registration/src/cardano/cip509/rbac

1 file changed

+7
-6
lines changed

rust/rbac-registration/src/cardano/cip509/rbac/pub_key.rs

Lines changed: 7 additions & 6 deletions
Original file line numberDiff line numberDiff line change
@@ -67,18 +67,19 @@ impl Decode<'_, ()> for SimplePublicKeyType {
6767
ed25519.copy_from_slice(&bytes);
6868
Ok(Self::Ed25519(Ed25519PublicKey(ed25519)))
6969
} else {
70-
Err(decode::Error::message("Invalid length for Ed25519 key"))
70+
Err(decode::Error::message(format!(
71+
"Invalid length for Ed25519 key, got {}",
72+
bytes.len()
73+
)))
7174
}
7275
},
7376
_ => Err(decode::Error::message("Unknown tag for Self")),
7477
}
7578
},
7679
minicbor::data::Type::Undefined => Ok(Self::Undefined),
77-
_ => {
78-
Err(decode::Error::message(
79-
"Invalid datatype for SimplePublicKeyType",
80-
))
81-
},
80+
_ => Err(decode::Error::message(
81+
"Invalid datatype for SimplePublicKeyType",
82+
)),
8283
}
8384
}
8485
}

0 commit comments

Comments
 (0)