Skip to content

Commit 9b541d0

Browse files
committed
lints on FCP-related items
clippy::{struct_field_names,upper_case_acronym}
1 parent 8031a82 commit 9b541d0

File tree

1 file changed

+10
-10
lines changed

1 file changed

+10
-10
lines changed

src/rfcbot.rs

Lines changed: 10 additions & 10 deletions
Original file line numberDiff line numberDiff line change
@@ -3,15 +3,15 @@ use serde::{Deserialize, Serialize};
33
use std::collections::HashMap;
44

55
#[derive(Serialize, Deserialize, Debug, Clone)]
6-
pub struct FCP {
6+
pub struct Fcp {
77
pub id: u32,
88
pub fk_issue: u32,
99
pub fk_initiator: u32,
1010
pub fk_initiating_comment: u64,
1111
pub disposition: Option<String>,
1212
pub fk_bot_tracking_comment: u64,
13-
pub fcp_start: Option<String>,
14-
pub fcp_closed: bool,
13+
pub start: Option<String>,
14+
pub closed: bool,
1515
}
1616
#[derive(Serialize, Deserialize, Debug, Clone)]
1717
pub struct Reviewer {
@@ -30,7 +30,7 @@ pub struct Concern {
3030
pub reviewer: Reviewer,
3131
}
3232
#[derive(Serialize, Deserialize, Debug, Clone)]
33-
pub struct FCPIssue {
33+
pub struct FcpIssue {
3434
pub id: u32,
3535
pub number: u32,
3636
pub fk_milestone: Option<u32>,
@@ -60,18 +60,18 @@ pub struct StatusComment {
6060
}
6161

6262
#[derive(Serialize, Deserialize, Debug, Clone)]
63-
pub struct FullFCP {
64-
pub fcp: FCP,
63+
pub struct FullFcp {
64+
pub fcp: Fcp,
6565
pub reviews: Vec<Review>,
6666
pub concerns: Vec<Concern>,
67-
pub issue: FCPIssue,
67+
pub issue: FcpIssue,
6868
pub status_comment: StatusComment,
6969
}
7070

71-
pub async fn get_all_fcps() -> anyhow::Result<HashMap<String, FullFCP>> {
71+
pub async fn get_all_fcps() -> anyhow::Result<HashMap<String, FullFcp>> {
7272
let url = Url::parse("https://rfcbot.rs/api/all")?;
73-
let res = reqwest::get(url).await?.json::<Vec<FullFCP>>().await?;
74-
let mut map: HashMap<String, FullFCP> = HashMap::new();
73+
let res = reqwest::get(url).await?.json::<Vec<FullFcp>>().await?;
74+
let mut map: HashMap<String, FullFcp> = HashMap::new();
7575
for full_fcp in res {
7676
map.insert(
7777
format!(

0 commit comments

Comments
 (0)