Skip to content

Commit

Permalink
chore: Fix lint warnings (#190)
Browse files Browse the repository at this point in the history
* apply code formatting
* fix clippy warnings
  • Loading branch information
scarmuega authored Sep 13, 2022
1 parent 85cf02d commit 6b2f230
Show file tree
Hide file tree
Showing 4 changed files with 6 additions and 6 deletions.
6 changes: 3 additions & 3 deletions pallas-addresses/src/lib.rs
Original file line number Diff line number Diff line change
Expand Up @@ -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)
Expand All @@ -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)
Expand Down Expand Up @@ -205,7 +205,7 @@ impl ShelleyDelegationPart {
Self::Null => vec![],
}
}

pub fn to_hex(&self) -> String {
let bytes = self.to_vec();
hex::encode(bytes)
Expand Down
2 changes: 1 addition & 1 deletion pallas-primitives/src/alonzo/model.rs
Original file line number Diff line number Diff line change
Expand Up @@ -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
Expand Down
2 changes: 1 addition & 1 deletion pallas-primitives/src/babbage/model.rs
Original file line number Diff line number Diff line change
Expand Up @@ -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
Expand Down
2 changes: 1 addition & 1 deletion pallas-traverse/src/hashes.rs
Original file line number Diff line number Diff line change
Expand Up @@ -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())
}
}

Expand Down

0 comments on commit 6b2f230

Please sign in to comment.