mirror of
https://github.com/matter-labs/teepot.git
synced 2025-07-21 07:03:56 +02:00
refactor: combine equivalent match branches
This commit is contained in:
parent
36afc85d38
commit
6a9e035d19
4 changed files with 10 additions and 9 deletions
|
@ -38,8 +38,7 @@ impl FromStr for TcbLevel {
|
|||
|
||||
fn from_str(s: &str) -> Result<Self, Self::Err> {
|
||||
match s.to_ascii_lowercase().as_str() {
|
||||
"ok" => Ok(TcbLevel::Ok),
|
||||
"uptodate" => Ok(TcbLevel::Ok),
|
||||
"ok" | "uptodate" => Ok(TcbLevel::Ok),
|
||||
"configneeded" => Ok(TcbLevel::ConfigNeeded),
|
||||
"configandswhardeningneeded" => Ok(TcbLevel::ConfigAndSwHardeningNeeded),
|
||||
"swhardeningneeded" => Ok(TcbLevel::SwHardeningNeeded),
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue