Drop nested list variable in command
The enum variant is the value this code-path requires. The inner bool doesn't do anything, so it can go away.
This commit is contained in:
@@ -14,8 +14,5 @@ pub struct Args {
|
||||
|
||||
#[derive(Subcommand, Debug)]
|
||||
pub enum Commands {
|
||||
ListReleases {
|
||||
#[arg(short, long)]
|
||||
list: bool,
|
||||
},
|
||||
ListReleases,
|
||||
}
|
||||
|
||||
@@ -10,7 +10,7 @@ async fn main() -> Result<(), Error> {
|
||||
let args = Args::parse();
|
||||
|
||||
match args.command {
|
||||
gt_tools::cli::Commands::ListReleases { list } => {
|
||||
gt_tools::cli::Commands::ListReleases => {
|
||||
let request_url = format!(
|
||||
"http:/localhost:3000/api/v1/repos/{owner}/{repo}/releases",
|
||||
owner = "robert",
|
||||
|
||||
Reference in New Issue
Block a user