Skip to content

Commit 36d7c45

Browse files
Fix some review comments
1 parent 6c71c5a commit 36d7c45

File tree

2 files changed

+4
-6
lines changed

2 files changed

+4
-6
lines changed

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

Lines changed: 3 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -127,7 +127,7 @@ impl Cip509 {
127127
)
128128
})?;
129129
let MultiEraTx::Conway(txn) = txn else {
130-
return Err(anyhow!("Unsupported era: {}", txn.era()));
130+
return Ok(None);
131131
};
132132

133133
let auxiliary_data = match &txn.auxiliary_data {
@@ -169,7 +169,7 @@ impl Cip509 {
169169
txn.transaction_body.auxiliary_data_hash.as_ref(),
170170
&cip509.report,
171171
);
172-
// The following checks are only performed for the role 0.
172+
// The following checks are only performed for the role 0.
173173
if let Some(role_data) = cip509.role_data(RoleNumber::ROLE_0) {
174174
validate_stake_public_key(txn, cip509.certificate_uris(), &cip509.report);
175175
validate_role_signing_key(role_data, &cip509.report);
@@ -395,14 +395,12 @@ fn payment_history(
395395

396396
for (index, output) in txn.transaction_body.outputs.iter().enumerate() {
397397
let conway::PseudoTransactionOutput::PostAlonzo(output) = output else {
398-
report.other("Unsupported legacy transaction output", &context);
399398
continue;
400399
};
401400

402401
let address = match Address::from_bytes(&output.address) {
403402
Ok(Address::Shelley(a)) => a,
404-
Ok(a) => {
405-
report.other(&format!("Unexpected output address type: {a:?}"), &context);
403+
Ok(_) => {
406404
continue;
407405
},
408406
Err(e) => {

rust/rbac-registration/src/cardano/cip509/rbac/certs/c509.rs

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -7,7 +7,7 @@ use minicbor::{decode, Decode, Decoder};
77

88
use crate::cardano::cip509::rbac::{certs::C509CertInMetadatumReference, tag::KeyTag};
99

10-
/// Enum of possible X.509 DER certificate.
10+
/// An enum of possible C509 certificate values.
1111
#[allow(clippy::module_name_repetitions)]
1212
#[derive(Debug, PartialEq, Clone, Default)]
1313
pub enum C509Cert {

0 commit comments

Comments
 (0)