summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authormo khan <mo@mokhan.ca>2025-07-10 13:13:16 -0600
committermo khan <mo@mokhan.ca>2025-07-10 13:13:16 -0600
commitecf43aac41e27f6546858cd98a152ac761a9afb6 (patch)
tree59067b99e180c6cf64790a40a60796714a24c98e
parent01959b16a21b22b5df5f16569c2a8e8f92beecef (diff)
refactor: rename generate to all
-rw-r--r--src/authorization/entities.rs2
-rw-r--r--src/bin/cli.rs2
2 files changed, 2 insertions, 2 deletions
diff --git a/src/authorization/entities.rs b/src/authorization/entities.rs
index 8c3f7955..4824fdd8 100644
--- a/src/authorization/entities.rs
+++ b/src/authorization/entities.rs
@@ -75,7 +75,7 @@ impl EntitiesRepository {
}
}
- pub async fn generate(&self) -> Result<Vec<CedarEntity>, Box<dyn std::error::Error>> {
+ pub async fn all(&self) -> Result<Vec<CedarEntity>, Box<dyn std::error::Error>> {
let client = reqwest::Client::new();
let mut entities = Vec::new();
let mut processed_groups = HashSet::new();
diff --git a/src/bin/cli.rs b/src/bin/cli.rs
index d0bbe989..fbd07d35 100644
--- a/src/bin/cli.rs
+++ b/src/bin/cli.rs
@@ -51,7 +51,7 @@ async fn main() -> Result<(), Box<dyn std::error::Error>> {
host,
} => {
let repository = EntitiesRepository::new(token, host, project);
- let entities = repository.generate().await?;
+ let entities = repository.all().await?;
let json = serde_json::to_string_pretty(&entities)?;
std::fs::write(output, json)?;
}