proto: Remove unused types (#36269)
This PR removes some unused types from the RPC protocol. Release Notes: - N/A
This commit is contained in:
parent
75f85b3aaa
commit
2a9d4599cd
3 changed files with 3 additions and 47 deletions
|
@ -998,19 +998,6 @@ impl RequestUsage {
|
|||
}
|
||||
}
|
||||
|
||||
pub fn from_proto(amount: u32, limit: proto::UsageLimit) -> Option<Self> {
|
||||
let limit = match limit.variant? {
|
||||
proto::usage_limit::Variant::Limited(limited) => {
|
||||
UsageLimit::Limited(limited.limit as i32)
|
||||
}
|
||||
proto::usage_limit::Variant::Unlimited(_) => UsageLimit::Unlimited,
|
||||
};
|
||||
Some(RequestUsage {
|
||||
limit,
|
||||
amount: amount as i32,
|
||||
})
|
||||
}
|
||||
|
||||
fn from_headers(
|
||||
limit_name: &str,
|
||||
amount_name: &str,
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue