chore: Fix lint warnings (#190)
* apply code formatting * fix clippy warnings
This commit is contained in:
parent
85cf02dec4
commit
6b2f23059f
4 changed files with 6 additions and 6 deletions
|
|
@ -143,7 +143,7 @@ impl ShelleyPaymentPart {
|
|||
Self::Script(x) => x.to_vec(),
|
||||
}
|
||||
}
|
||||
|
||||
|
||||
pub fn to_hex(&self) -> String {
|
||||
let bytes = self.to_vec();
|
||||
hex::encode(bytes)
|
||||
|
|
@ -152,7 +152,7 @@ impl ShelleyPaymentPart {
|
|||
pub fn to_bech32(&self) -> Result<String, Error> {
|
||||
let hrp = match self {
|
||||
Self::Key(_) => "addr_vkh",
|
||||
Self::Script(_) => "addr_shared_vkh"
|
||||
Self::Script(_) => "addr_shared_vkh",
|
||||
};
|
||||
let bytes = self.to_vec();
|
||||
encode_bech32(&bytes, hrp)
|
||||
|
|
@ -205,7 +205,7 @@ impl ShelleyDelegationPart {
|
|||
Self::Null => vec![],
|
||||
}
|
||||
}
|
||||
|
||||
|
||||
pub fn to_hex(&self) -> String {
|
||||
let bytes = self.to_vec();
|
||||
hex::encode(bytes)
|
||||
|
|
|
|||
|
|
@ -1412,7 +1412,7 @@ impl<'b> From<MintedBlock<'b>> for Block {
|
|||
.to_vec()
|
||||
.into_iter()
|
||||
.map(|x| x.unwrap())
|
||||
.map(|x| WitnessSet::from(x))
|
||||
.map(WitnessSet::from)
|
||||
.collect(),
|
||||
auxiliary_data_set: x
|
||||
.auxiliary_data_set
|
||||
|
|
|
|||
|
|
@ -609,7 +609,7 @@ impl<'b> From<MintedBlock<'b>> for Block {
|
|||
.to_vec()
|
||||
.into_iter()
|
||||
.map(|x| x.unwrap())
|
||||
.map(|x| WitnessSet::from(x))
|
||||
.map(WitnessSet::from)
|
||||
.collect(),
|
||||
auxiliary_data_set: x
|
||||
.auxiliary_data_set
|
||||
|
|
|
|||
|
|
@ -81,7 +81,7 @@ impl ComputeHash<32> for alonzo::PlutusData {
|
|||
|
||||
impl OriginalHash<32> for KeepRaw<'_, alonzo::PlutusData> {
|
||||
fn original_hash(&self) -> Hash<32> {
|
||||
Hasher::<256>::hash(&self.raw_cbor())
|
||||
Hasher::<256>::hash(self.raw_cbor())
|
||||
}
|
||||
}
|
||||
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue