fix latest clippy (#2597)

This commit is contained in:
extrawurst
2025-04-07 16:06:00 +02:00
committed by GitHub
parent 7f75307f6e
commit cc907996f4
21 changed files with 44 additions and 24 deletions
+1 -1
View File
@@ -271,7 +271,7 @@ pub fn config_is_pull_rebase(repo_path: &RepoPath) -> Result<bool> {
let value =
rebase.value().map(String::from).unwrap_or_default();
return Ok(value == "true");
};
}
Ok(false)
}
-1
View File
@@ -55,7 +55,6 @@ pub fn amend(
/// Wrap `Repository::signature` to allow unknown user.name.
///
/// See <https://github.com/gitui-org/gitui/issues/79>.
#[allow(clippy::redundant_pub_crate)]
pub(crate) fn signature_allow_undefined_name(
repo: &Repository,
) -> std::result::Result<Signature<'_>, git2::Error> {
+2 -1
View File
@@ -17,6 +17,7 @@ use crate::{
use crossbeam_channel::Sender;
use git2::{PackBuilderStage, PushOptions};
use scopetime::scope_time;
use std::fmt::Write as _;
///
pub trait AsyncProgress: Clone + Send + Sync {
@@ -182,7 +183,7 @@ pub fn push_raw(
if let Ok(Some(branch_upstream_merge)) =
get_branch_upstream_merge(repo_path, branch)
{
push_ref.push_str(&format!(":{branch_upstream_merge}"));
let _ = write!(push_ref, ":{branch_upstream_merge}");
}
}