Skip to content

Commit 817314b

Browse files
cargo fmt
1 parent 5942900 commit 817314b

File tree

1 file changed

+27
-31
lines changed

1 file changed

+27
-31
lines changed

modules/stake_delta_filter/src/utils.rs

Lines changed: 27 additions & 31 deletions
Original file line numberDiff line numberDiff line change
@@ -434,39 +434,35 @@ mod test {
434434
payload: byron_address.payload.to_vec(),
435435
})),
436436

437-
addresses::Address::Shelley(shelley_address) => {
438-
Ok(Address::Shelley(ShelleyAddress {
439-
network: map_network(shelley_address.network())?,
437+
addresses::Address::Shelley(shelley_address) => Ok(Address::Shelley(ShelleyAddress {
438+
network: map_network(shelley_address.network())?,
440439

441-
payment: match shelley_address.payment() {
442-
addresses::ShelleyPaymentPart::Key(hash) => {
443-
ShelleyAddressPaymentPart::PaymentKeyHash(hash.to_vec())
444-
}
445-
addresses::ShelleyPaymentPart::Script(hash) => {
446-
ShelleyAddressPaymentPart::ScriptHash(hash.to_vec())
447-
}
448-
},
440+
payment: match shelley_address.payment() {
441+
addresses::ShelleyPaymentPart::Key(hash) => {
442+
ShelleyAddressPaymentPart::PaymentKeyHash(hash.to_vec())
443+
}
444+
addresses::ShelleyPaymentPart::Script(hash) => {
445+
ShelleyAddressPaymentPart::ScriptHash(hash.to_vec())
446+
}
447+
},
449448

450-
delegation: match shelley_address.delegation() {
451-
addresses::ShelleyDelegationPart::Null => {
452-
ShelleyAddressDelegationPart::None
453-
}
454-
addresses::ShelleyDelegationPart::Key(hash) => {
455-
ShelleyAddressDelegationPart::StakeKeyHash(hash.to_vec())
456-
}
457-
addresses::ShelleyDelegationPart::Script(hash) => {
458-
ShelleyAddressDelegationPart::ScriptHash(hash.to_vec())
459-
}
460-
addresses::ShelleyDelegationPart::Pointer(pointer) => {
461-
ShelleyAddressDelegationPart::Pointer(ShelleyAddressPointer {
462-
slot: pointer.slot(),
463-
tx_index: pointer.tx_idx(),
464-
cert_index: pointer.cert_idx(),
465-
})
466-
}
467-
},
468-
}))
469-
}
449+
delegation: match shelley_address.delegation() {
450+
addresses::ShelleyDelegationPart::Null => ShelleyAddressDelegationPart::None,
451+
addresses::ShelleyDelegationPart::Key(hash) => {
452+
ShelleyAddressDelegationPart::StakeKeyHash(hash.to_vec())
453+
}
454+
addresses::ShelleyDelegationPart::Script(hash) => {
455+
ShelleyAddressDelegationPart::ScriptHash(hash.to_vec())
456+
}
457+
addresses::ShelleyDelegationPart::Pointer(pointer) => {
458+
ShelleyAddressDelegationPart::Pointer(ShelleyAddressPointer {
459+
slot: pointer.slot(),
460+
tx_index: pointer.tx_idx(),
461+
cert_index: pointer.cert_idx(),
462+
})
463+
}
464+
},
465+
})),
470466

471467
addresses::Address::Stake(stake_address) => Ok(Address::Stake(StakeAddress {
472468
network: map_network(stake_address.network())?,

0 commit comments

Comments
 (0)