chore: remove useless clone

This commit is contained in:
Anna 2023-08-31 00:52:21 -04:00
parent fae0f91405
commit fae03a94e5
Signed by: anna
GPG Key ID: D0943384CD9F87D1

View File

@ -450,7 +450,6 @@ fn main() -> Result<()> {
.context("missing timestamp")? .context("missing timestamp")?
.parse::<i64>() .parse::<i64>()
.context("invalid timestamp")?; .context("invalid timestamp")?;
// let original = timestamp;
let author_len = author_parts.len(); let author_len = author_parts.len();
let committer_len = committer_parts.len(); let committer_len = committer_parts.len();
@ -472,7 +471,6 @@ fn main() -> Result<()> {
let timestamp = Arc::clone(&timestamp); let timestamp = Arc::clone(&timestamp);
let message = message.clone(); let message = message.clone();
let byte_prefix = byte_prefix.clone(); let byte_prefix = byte_prefix.clone();
let nibble_values = nibble_values.clone();
let mut author_parts = author_parts.clone(); let mut author_parts = author_parts.clone();
let mut committer_parts = committer_parts.clone(); let mut committer_parts = committer_parts.clone();
let mut header_lines = header_lines.clone(); let mut header_lines = header_lines.clone();
@ -630,10 +628,8 @@ fn main() -> Result<()> {
} }
let hash = sha1.finalize_reset(); let hash = sha1.finalize_reset();
// let hash = data_encoding::HEXLOWER.encode(&hash);
bar.inc(1); bar.inc(1);
// if hash.starts_with(&prefix) {
if hash[0..byte_prefix.len()] == byte_prefix { if hash[0..byte_prefix.len()] == byte_prefix {
// check the nibble // check the nibble
if let Some(values) = nibble_values { if let Some(values) = nibble_values {