@@ -3,15 +3,15 @@ use serde::{Deserialize, Serialize};
3
3
use std:: collections:: HashMap ;
4
4
5
5
#[ derive( Serialize , Deserialize , Debug , Clone ) ]
6
- pub struct FCP {
6
+ pub struct Fcp {
7
7
pub id : u32 ,
8
8
pub fk_issue : u32 ,
9
9
pub fk_initiator : u32 ,
10
10
pub fk_initiating_comment : u64 ,
11
11
pub disposition : Option < String > ,
12
12
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 ,
15
15
}
16
16
#[ derive( Serialize , Deserialize , Debug , Clone ) ]
17
17
pub struct Reviewer {
@@ -30,7 +30,7 @@ pub struct Concern {
30
30
pub reviewer : Reviewer ,
31
31
}
32
32
#[ derive( Serialize , Deserialize , Debug , Clone ) ]
33
- pub struct FCPIssue {
33
+ pub struct FcpIssue {
34
34
pub id : u32 ,
35
35
pub number : u32 ,
36
36
pub fk_milestone : Option < u32 > ,
@@ -60,18 +60,18 @@ pub struct StatusComment {
60
60
}
61
61
62
62
#[ derive( Serialize , Deserialize , Debug , Clone ) ]
63
- pub struct FullFCP {
64
- pub fcp : FCP ,
63
+ pub struct FullFcp {
64
+ pub fcp : Fcp ,
65
65
pub reviews : Vec < Review > ,
66
66
pub concerns : Vec < Concern > ,
67
- pub issue : FCPIssue ,
67
+ pub issue : FcpIssue ,
68
68
pub status_comment : StatusComment ,
69
69
}
70
70
71
- pub async fn get_all_fcps ( ) -> anyhow:: Result < HashMap < String , FullFCP > > {
71
+ pub async fn get_all_fcps ( ) -> anyhow:: Result < HashMap < String , FullFcp > > {
72
72
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 ( ) ;
75
75
for full_fcp in res {
76
76
map. insert (
77
77
format ! (
0 commit comments