Merge pull request #894 from tolik518/cargo-clippy-fix

fixed cargo clippy warnings
This commit is contained in:
Denis Isidoro 2024-05-07 15:17:55 -03:00 committed by GitHub
commit 7575ca2435
No known key found for this signature in database
GPG key ID: B5690EEEBB952194
3 changed files with 4 additions and 11 deletions

View file

@ -100,7 +100,7 @@ impl Config {
}
pub fn tealdeer(&self) -> bool {
self.yaml.client.tealdeer.clone()
self.yaml.client.tealdeer
}
pub fn shell(&self) -> String {

View file

@ -80,6 +80,7 @@ pub struct Shell {
#[derive(Deserialize, Debug)]
#[serde(default)]
#[derive(Default)]
pub struct Client {
pub tealdeer: bool,
}
@ -169,9 +170,3 @@ impl Default for Shell {
}
}
}
impl Default for Client {
fn default() -> Self {
Self { tealdeer: false }
}
}

View file

@ -81,12 +81,10 @@ impl FinderChoice {
&& patch < MIN_FZF_VERSION_PATCH
{
eprintln!(
"Warning: Fzf version {}.{} does not support the preview window layout used by navi.",
major, minor
"Warning: Fzf version {major}.{minor} does not support the preview window layout used by navi.",
);
eprintln!(
"Consider updating Fzf to a version >= {}.{}.{} or use a compatible layout.",
MIN_FZF_VERSION_MAJOR, MIN_FZF_VERSION_MINOR, MIN_FZF_VERSION_PATCH
"Consider updating Fzf to a version >= {MIN_FZF_VERSION_MAJOR}.{MIN_FZF_VERSION_MINOR}.{MIN_FZF_VERSION_PATCH} or use a compatible layout.",
);
process::exit(1);
}