Skip to content

Commit

Permalink
Lints and parentheses fix
Browse files Browse the repository at this point in the history
  • Loading branch information
AaronFeickert committed Sep 27, 2023
1 parent a67b5ec commit 23c8282
Show file tree
Hide file tree
Showing 2 changed files with 2 additions and 5 deletions.
2 changes: 1 addition & 1 deletion base_layer/core/src/validation/helpers.rs
Original file line number Diff line number Diff line change
Expand Up @@ -76,7 +76,7 @@ pub fn calc_median_timestamp(timestamps: &[EpochTime]) -> EpochTime {
// To make the linter happy, we use `u64::MAX` in the impossible case that the cast fails
EpochTime::from(
u64::try_from(
u128::from(timestamps[mid_index - 1].as_u64()) + u128::from(timestamps[mid_index].as_u64()) / 2,
(u128::from(timestamps[mid_index - 1].as_u64()) + u128::from(timestamps[mid_index].as_u64())) / 2,
)
.unwrap_or(u64::MAX),
)
Expand Down
5 changes: 1 addition & 4 deletions infrastructure/tari_script/src/script.rs
Original file line number Diff line number Diff line change
Expand Up @@ -20,10 +20,7 @@ use std::{cmp::Ordering, collections::HashSet, convert::TryFrom, fmt, io, ops::D

use blake2::Blake2b;
use borsh::{BorshDeserialize, BorshSerialize};
use digest::{
consts::U32,
Digest,
};
use digest::{consts::U32, Digest};
use integer_encoding::{VarIntReader, VarIntWriter};
use sha2::Sha256;
use sha3::Sha3_256;
Expand Down

0 comments on commit 23c8282

Please sign in to comment.