Skip to content

Commit

Permalink
update function name
Browse files Browse the repository at this point in the history
  • Loading branch information
Esgrove committed Oct 26, 2024
1 parent 64a572e commit df0599c
Show file tree
Hide file tree
Showing 3 changed files with 3 additions and 7 deletions.
6 changes: 1 addition & 5 deletions python-pyo3/src/lib.rs
Original file line number Diff line number Diff line change
Expand Up @@ -31,7 +31,6 @@ fn all(
.map_err(vault_error_to_anyhow)?;

cli::list_all_keys(&vault).await?;

Ok(())
})
}
Expand All @@ -51,7 +50,6 @@ fn delete(
.map_err(vault_error_to_anyhow)?;

cli::delete(&vault, key).await?;

Ok(())
})
}
Expand Down Expand Up @@ -159,8 +157,7 @@ fn info(
#[pyfunction(signature = (region=None, quiet=false))]
fn id(region: Option<String>, quiet: bool) -> PyResult<()> {
Runtime::new()?.block_on(async {
cli::get_aws_account_id(region, quiet).await?;

cli::print_aws_account_id(region, quiet).await?;
Ok(())
})
}
Expand All @@ -175,7 +172,6 @@ fn init(
) -> PyResult<()> {
Runtime::new()?.block_on(async {
cli::init_vault_stack(vault_stack.or(name), region, bucket, quiet).await?;

Ok(())
})
}
Expand Down
2 changes: 1 addition & 1 deletion rust/src/cli.rs
Original file line number Diff line number Diff line change
Expand Up @@ -240,7 +240,7 @@ pub async fn decrypt(
}

/// Print the information from AWS STS "get caller identity" call.
pub async fn get_aws_account_id(region: Option<String>, quiet: bool) -> Result<()> {
pub async fn print_aws_account_id(region: Option<String>, quiet: bool) -> Result<()> {
let config = crate::get_aws_config(region).await;
let client = crate::aws_sts_client(&config);
let result = client.get_caller_identity().send().await?;
Expand Down
2 changes: 1 addition & 1 deletion rust/src/main.rs
Original file line number Diff line number Diff line change
Expand Up @@ -290,7 +290,7 @@ async fn run(args: Args) -> Result<()> {
cli::generate_shell_completion(shell, Args::command(), install, args.quiet)?;
}
Command::Id {} => {
cli::get_aws_account_id(args.region, args.quiet).await?;
cli::print_aws_account_id(args.region, args.quiet).await?;
}
// All other commands can use the same single Vault
Command::All {}
Expand Down

0 comments on commit df0599c

Please sign in to comment.