clippy warnings fix

This commit is contained in:
lemonsh 2023-05-28 18:14:58 +02:00
parent a3c8ef9f74
commit ea6b2a3850
2 changed files with 5 additions and 6 deletions

View File

@ -119,10 +119,10 @@ pub(crate) async fn run(cmd: PortForwardsCommand, state: &AppState) -> Result<()
}
})
.await?;
if !modified {
cprintln!("<red!>No port with id {id} exists");
if modified {
cprintln!("<green!>Done!");
} else {
cprintln!("<green!>Done!")
cprintln!("<red!>No port with id {id} exists");
}
}
}

View File

@ -2,13 +2,12 @@ use crate::{cli::ShellCommand, utils::QuotableArgs};
use clap::{FromArgMatches, Parser};
use cli::Args;
use color_eyre::Result;
use color_print::{cformat, cprintln, cstr};
use color_print::{cformat, cprintln};
use connectbox::ConnectBox;
use rustyline::{
error::ReadlineError,
highlight::Highlighter,
history::{DefaultHistory, FileHistory, MemHistory},
Completer, DefaultEditor, Editor, Helper, Hinter, Validator,
Completer, Editor, Helper, Hinter, Validator,
};
use std::borrow::Cow;