Skip to content

Commit b7d8d5d

Browse files
committed
consistent comments and parameter names
1 parent dc39eca commit b7d8d5d

File tree

3 files changed

+14
-14
lines changed

3 files changed

+14
-14
lines changed

src/interface/allocation.rs

Lines changed: 6 additions & 6 deletions
Original file line numberDiff line numberDiff line change
@@ -35,20 +35,20 @@ pub async fn allocation(
3535
/// ```
3636
pub async fn allocations(
3737
client: &client::Client,
38-
assignment_type_id: Option<enums::AssignmentType>,
39-
member_id: Option<types::UUID>,
38+
assignment_type: Option<enums::AssignmentType>,
39+
member: Option<types::UUID>,
4040
start_date: Option<types::Date>,
4141
end_date: Option<types::Date>,
4242
) -> Result<allocation::Allocations, Box<dyn std::error::Error>> {
4343
// initialize params
4444
let mut params = String::from("limit=100");
4545

4646
// optional parameters for LIST
47-
if let Some(assignment_type_id) = assignment_type_id {
48-
write!(params, "&assignmentTypeId={}", assignment_type_id)?;
47+
if let Some(assignment_type) = assignment_type {
48+
write!(params, "&assignmentTypeId={}", assignment_type)?;
4949
}
50-
if let Some(member_id) = member_id {
51-
write!(params, "&memberId={}", member_id)?;
50+
if let Some(member) = member {
51+
write!(params, "&memberId={}", member)?;
5252
}
5353
if let Some(start_date) = start_date {
5454
write!(params, "&startOnBefore={}", start_date)?;

src/interface/cost.rs

Lines changed: 4 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -31,17 +31,17 @@ pub async fn cost(
3131
/// ```
3232
pub async fn costs(
3333
client: &client::Client,
34-
member_id: Option<types::UUID>,
34+
member: Option<types::UUID>,
3535
) -> Result<cost::Costs, Box<dyn std::error::Error>> {
3636
// initialize params
3737
let mut params = String::from("limit=100");
3838

3939
// optional parameters for LIST
40-
if let Some(member_id) = member_id {
41-
write!(params, "&memberId={}", member_id)?;
40+
if let Some(member) = member {
41+
write!(params, "&memberId={}", member)?;
4242
}
4343

44-
// retrieve clients
44+
// retrieve cost target periods
4545
Ok(client
4646
.read::<cost::Costs>("cost-periods", Some(&params))
4747
.await?)

src/interface/utilization.rs

Lines changed: 4 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -31,17 +31,17 @@ pub async fn utilization(
3131
/// ```
3232
pub async fn utilizations(
3333
client: &client::Client,
34-
member_id: Option<types::UUID>,
34+
member: Option<types::UUID>,
3535
) -> Result<utilization::Utilizations, Box<dyn std::error::Error>> {
3636
// initialize params
3737
let mut params = String::from("limit=100");
3838

3939
// optional parameters for LIST
40-
if let Some(member_id) = member_id {
41-
write!(params, "&memberId={}", member_id)?;
40+
if let Some(member) = member {
41+
write!(params, "&memberId={}", member)?;
4242
}
4343

44-
// retrieve clients
44+
// retrieve utilization target periods
4545
Ok(client
4646
.read::<utilization::Utilizations>("utilization-target-periods", Some(&params))
4747
.await?)

0 commit comments

Comments
 (0)